glibc/gshadow
Florian Weimer 969e9733c7 gshadow: Matching sgetsgent, sgetsgent_r ERANGE handling (bug 30151)
Before this change, sgetsgent_r did not set errno to ERANGE, but
sgetsgent only check errno, not the return value from sgetsgent_r.
Consequently, sgetsgent did not detect any error, and reported
success to the caller, without initializing the struct sgrp object
whose address was returned.

This commit changes sgetsgent_r to set errno as well.  This avoids
similar issues in applications which only change errno.

Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>
2023-03-07 10:01:44 +01:00
..
fgetsgent_r.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
fgetsgent.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
getsgent_r.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
getsgent.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
getsgnam_r.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
getsgnam.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
gshadow.h Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
Makefile gshadow: Matching sgetsgent, sgetsgent_r ERANGE handling (bug 30151) 2023-03-07 10:01:44 +01:00
putsgent.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
sgetsgent_r.c gshadow: Matching sgetsgent, sgetsgent_r ERANGE handling (bug 30151) 2023-03-07 10:01:44 +01:00
sgetsgent.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
tst-fgetsgent_r.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
tst-gshadow.c
tst-putsgent.c Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
tst-sgetsgent.c gshadow: Matching sgetsgent, sgetsgent_r ERANGE handling (bug 30151) 2023-03-07 10:01:44 +01:00
Versions