diff --git a/ChangeLog b/ChangeLog index 5940ba74..cdc10f78 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2010-02-14 Michael Bunk + + * NEWS, lib/gshadow.c: Fix parsing of gshadow entries. + 2010-01-30 Paweł Hajdan, Jr. * NEWS: Add support for TCB. diff --git a/NEWS b/NEWS index 9d4bebfe..01c1df90 100644 --- a/NEWS +++ b/NEWS @@ -15,6 +15,8 @@ shadow-4.1.4.2 -> shadow-4.1.4.3 UNRELEASED sending a SIGTERM), and kill it only if it did not terminate by itself. No delay will be enforced if the child cooperates. * Default ENV_SUPATH is /sbin:/bin:/usr/sbin:/usr/bin +- newgrp, sg, groupmems + * Fix parsing of gshadow entries. *** translation * Updated Czech translation. diff --git a/lib/gshadow.c b/lib/gshadow.c index 8427fc23..e5a0f61e 100644 --- a/lib/gshadow.c +++ b/lib/gshadow.c @@ -222,6 +222,7 @@ void endsgent (void) if (NULL == buf) { return NULL; } + buflen = BUFSIZ; } if (NULL == fp) { @@ -229,9 +230,9 @@ void endsgent (void) } #ifdef USE_NIS - while (fgetsx (buf, (int) sizeof buf, fp) == buf) + while (fgetsx (buf, (int) buflen, fp) == buf) #else - if (fgetsx (buf, (int) sizeof buf, fp) == buf) + if (fgetsx (buf, (int) buflen, fp) == buf) #endif { while ( ((cp = strrchr (buf, '\n')) == NULL)