From 4f667bb442ad06bf98370bfddf4869b727672fc3 Mon Sep 17 00:00:00 2001 From: nekral-guest Date: Fri, 20 Aug 2010 20:35:52 +0000 Subject: [PATCH] * lib/groupio.c: Avoid implicit conversion from signed to unsigned. --- ChangeLog | 4 ++++ lib/groupio.c | 11 +++++++---- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 31e2fee7..5bcb5531 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2010-08-20 Nicolas François + + * lib/groupio.c: Avoid implicit conversion from signed to unsigned. + 2010-08-20 Nicolas François * lib/commonio.c: Make sure there are no NULL pointer dereference. diff --git a/lib/groupio.c b/lib/groupio.c index 9ddca70c..1cf143fb 100644 --- a/lib/groupio.c +++ b/lib/groupio.c @@ -382,16 +382,19 @@ static int split_groups (unsigned int max_members) struct commonio_entry *new; struct group *new_gptr; unsigned int members = 0; - int i; + unsigned int i; /* Check if this group must be split */ - if (!gr->changed) + if (!gr->changed) { continue; - if (NULL == gptr) + } + if (NULL == gptr) { continue; + } for (members = 0; NULL != gptr->gr_mem[members]; members++); - if (members <= max_members) + if (members <= max_members) { continue; + } new = (struct commonio_entry *) malloc (sizeof *new); if (NULL == new) {