Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date: Tue, 6 Jun 2017 12:21:39 -0400
From: Rudolph Pereira <>
Subject: [PATCH] fix errno not being set to ERANGE by getgr, getpw, and getspnam


currently, the getgr, getpw, and getspnam functions in musl return ERANGE
when the allocated buffer is not large enough, but do not set errno to the
same value. This causes issues with utilities, for example the "shadow"
utilities (useradd/mod, groupmod, etc.) which assume this behaviour (which
at least gnu libc exhibits) and leads to groups having a small limit on the
number of members.

The attached patch, against 1.1.16, corrects this.


Content of type "text/html" skipped

View attachment "1100-getX-errno.patch" of type "text/x-patch" (1120 bytes)

Powered by blists - more mailing lists

Your e-mail address:

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.