Patch for Bug #1188
Thorsten Kukuk
kukuk@suse.de
Tue Aug 16 11:06:00 GMT 2005
Hi,
The following patch is correct should be applied to glibc 2.3
and head:
2005-08-10 Sergio Gelato <Sergio.Gelato@astro.su.se>
[BZ #1188]
* nis/nss_nis/nis-netgrp.c (_nss_nis_setnetgrent): Change assert check
from (len > 0) to (len >= 0).
--- nis/nss_nis/nis-netgrp.c
+++ nis/nss_nis/nis-netgrp.c
@@ -75,7 +75,7 @@ _nss_nis_setnetgrent (const char *group,
which is one byte larger than the value in LEN specifies
and the last byte is filled with NUL. So we can simply
use that buffer. */
- assert (len > 0);
+ assert (len >= 0);
assert (malloc_usable_size (netgrp->data) >= len + 1);
assert (netgrp->data[len] == '\0');
--
Thorsten Kukuk http://www.suse.de/~kukuk/ kukuk@suse.de
SUSE LINUX Products GmbH Maxfeldstr. 5 D-90409 Nuernberg
--------------------------------------------------------------------
Key fingerprint = A368 676B 5E1B 3E46 CFCE 2D97 F8FD 4E23 56C6 FB4B
More information about the Libc-hacker
mailing list