Commit ID: 1005E4A05924FCEF49D
CVSROOT: /cvs
Module name: src
Changes by: [email protected] 2020/02/17 03:28:01 UTC
Modified files:
lib/libc/stdlib: getenv.3 getenv.c putenv.c setenv.c
Log message:
modernise getenv/setenv/putenv/unsetenv:
• drop historic setenv("foo=","=bar") setting "foo" to "bar"
as prodded by dalias
• getenv("foo=bar") now doesn’t getenv("foo")…
• many more EINVAL checks for sanity
• all are now environ==NULL safe
• size_t not int
• document instances touched explicitly (cf. commitid 100568BF70414C190EB
but cid 100568C1B486A69D09B also, which reverted getenv to first match,
as something in Perl broke…)
To generate a diff of this changeset, execute the following commands:
cvs -R rdiff -kk -upr1.2 -r1.3 src/lib/libc/stdlib/getenv.3
cvs -R rdiff -kk -upr1.3 -r1.4 src/lib/libc/stdlib/getenv.c
cvs -R rdiff -kk -upr1.1.1.3 -r1.2 src/lib/libc/stdlib/putenv.c
cvs -R rdiff -kk -upr1.7 -r1.8 src/lib/libc/stdlib/setenv.c