lib/setenv.c


Log

Author Commit Date CI Message
Paul Eggert b9bfe784 2015-01-01T01:38:23 version-etc: new year * doc/gnulib.texi: * lib/version-etc.c (COPYRIGHT_YEAR): Update copyright date. * all files: Run 'make update-copyright'.
Eric Blake 1276a2c5 2014-01-01T00:04:40 maint: update copyright I ran 'make update-copyright'. Signed-off-by: Eric Blake <eblake@redhat.com>
Paul Eggert 49adc728 2013-02-11T14:58:56 unsetenv etc.: port to Solaris 11 + GNU Emacs * lib/canonicalize-lgpl.c, lib/getaddrinfo.c, lib/getdelim.c: * lib/glob.c, lib/random_r.c, lib/setenv.c, lib/tsearch.c: * lib/unsetenv.c (_GL_ARG_NONNULL): Define before including <config.h>. GNU Emacs's <config.h> includes <stdlib.h> (which is not a great idea but is too painful to fix right now), and without this gnulib change <stdlib.h> was defining _GL_ARG_NONNULL incorrectly when compiling unsetenv.c on Solaris 11. Fix the problem for unsetenv.c, and fix other similar occurrences.
Eric Blake 9fc81090 2013-01-01T00:50:58 maint: update all copyright year number ranges Run "make update-copyright". Compare to commit 1602f0a from last year. Signed-off-by: Eric Blake <eblake@redhat.com>
Paul Eggert 51e801f2 2012-01-05T23:53:49 In commentary, do not use ` to quote.
Jim Meyering 1602f0af 2012-01-01T10:04:58 maint: update all copyright year number ranges Run "make update-copyright".
Bruno Haible c00787b6 2011-06-05T14:31:51 setenv: Avoid gcc warning. * lib/setenv.c (setenv): Provide declaration if system lacks it.
Paul Eggert 8cce8985 2011-04-08T11:31:54 * lib/setenv.c (_GL_USE_STDLIB_ALLOC, malloc, realloc): Likewise.
Jim Meyering d60f3b0c 2011-01-01T20:17:23 maint: update almost all copyright ranges to include 2011 Run the new "make update-copyright" rule.
Bruno Haible fc06be3f 2010-06-09T12:47:59 Avoid relocwrapper link errors due to gnulib replacement functions.
Bruno Haible 7c59efd8 2010-06-09T12:40:40 Module setenv does not depend on 'malloc-posix', 'realloc-posix'.
Eric Blake e37c1207 2010-04-16T14:21:29 setenv: allow compilation with C++ * lib/setenv.c (__add_to_environ): Add a cast. Also, drop use of register keyword. Signed-off-by: Eric Blake <eblake@redhat.com>
Jim Meyering b2e2010c 2010-01-01T10:31:12 update nearly all FSF copyright year lists to include 2010 Use the same procedure as for 2009, outlined in http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/20081
Bruno Haible 69482508 2009-12-11T01:15:28 New module 'arg-nonnull'. Declare which arguments expect non-NULL values.
Bruno Haible 441aa304 2009-12-10T20:28:30 Use spaces for indentation, not tabs.
Eric Blake 8dffeb6f 2009-11-14T22:13:10 setenv, unsetenv: work around various bugs POSIX requires setenv(NULL,"",0), setenv("a=b","",0), unsetenv(NULL), and unsetenv("a=b") to fail with EINVAL, but many BSD implementations lack validation. The gnulib replacement for void unsetenv did not do validation, and the replacement for setenv was out of sync with glibc. Also, some BSD implementations of setenv("a","==",1) eat the leading '='. See also some recent Austin Group interpretations on environ: http://austingroupbugs.net/view.php?id=167 http://austingroupbugs.net/view.php?id=185 * lib/setenv.c (setenv) [!HAVE_SETENV]: Resync from glibc. (setenv) [HAVE_SETENV]: Work around bugs. * lib/unsetenv.c (unsetenv) [HAVE_UNSETENV]: Work around bugs. * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE, gl_FUNC_UNSETENV): Check for bugs. (gl_FUNC_SETENV): Write in terms of gl_FUNC_SETENV_SEPARATE. * m4/environ.m4 (gl_ENVIRON): Avoid expand-before-require. * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Update defaults. * modules/stdlib (Makefile.am): Update substitutions. * lib/stdlib.in.h (setenv, unsetenv): Update prototypes. * doc/posix-functions/setenv.texi (setenv): Document the bugs. * doc/posix-functions/unsetenv.texi (unsetenv): Likewise. * modules/setenv-tests: New test. * modules/unsetenv-tests: Likewise. * tests/test-setenv.c: New file. * tests/test-unsetenv.c: Likewise. Signed-off-by: Eric Blake <ebb9@byu.net>
Bruno Haible 22eb7728 2008-02-24T16:40:15 New module 'environ'.
Bruno Haible 81e61b22 2007-12-26T16:20:10 Split setenv module into setenv and unsetenv. Get rid of setenv.h.
Bruno Haible 57fdfd3f 2007-10-07T19:14:58 Change copyright notice from GPLv2+ to GPLv3+.
Bruno Haible 90988ede 2007-06-09T11:11:14 Update after allocsa -> malloca renaming.
Bruno Haible 44381706 2007-03-03T19:42:31 Make it possible to compile setenv.c separately, unconditionally.
Paul Eggert 0632e115 2006-09-13T22:38:14 * _fpending.c: Include <config.h> unconditionally, since we no longer worry about uses that don't define HAVE_CONFIG_H. * acl.c, alloca.c, argmatch.c, atexit.c, backupfile.c: * basename.c, c-stack.c, c-strtod.c, calloc.c, canon-host.c: * canonicalize.c, chdir-long.c, chdir-safer.c, chown.c: * cloexec.c, close-stream.c, closeout.c, creat-safer.c: * cycle-check.c, diacrit.c, dirchownmod.c, dirfd.c, dirname.c: * dup-safer.c, dup2.c, error.c, euidaccess.c, exclude.c: * exitfail.c, fchmodat.c, fchown-stub.c, fd-safer.c: * file-type.c, fileblocks.c, filemode.c, filenamecat.c: * fnmatch.c, fopen-safer.c, fprintftime.c, free.c, fsusage.c: * ftruncate.c, fts-cycle.c, fts.c, full-write.c, gai_strerror.c: * getcwd.c, getdate.y, getdomainname.c, getgroups.c: * gethostname.c, gethrxtime.c, getloadavg.c, getlogin_r.c: * getndelim2.c, getnline.c, getopt.c, getopt1.c, getpass.c: * gettime.c, gettimeofday.c, getugroups.c, getusershell.c: * glob.c, group-member.c, hard-locale.c, hash-pjw.c, hash.c: * human.c, idcache.c, inet_ntop.c, inet_pton.c, inttostr.c: * isdir.c, lchown.c, linebuffer.c, long-options.c, lstat.c: * malloc.c, md5.c, memcasecmp.c, memchr.c, memcmp.c, memcoll.c: * memcpy.c, memmove.c, memrchr.c, mkancesdirs.c, mkdir-p.c: * mkdir.c, mkdirat.c, mkstemp-safer.c, mkstemp.c, modechange.c: * mountlist.c, nanosleep.c, obstack.c, open-safer.c: * openat-die.c, openat.c, pagealign_alloc.c, physmem.c: * pipe-safer.c, posixtm.c, posixver.c, putenv.c, quote.c: * quotearg.c, raise.c, readtokens.c, readtokens0.c, readutmp.c: * realloc.c, regex.c, rename.c, rmdir.c, rpmatch.c, safe-read.c: * same.c, save-cwd.c, savedir.c, setenv.c, settime.c, sha1.c: * sig2str.c, snprintf.c, strdup.c, strerror.c, strftime.c: * stripslash.c, strndup.c, strnlen.c, strpbrk.c, strtod.c: * strtoimax.c, strtol.c, strverscmp.c, tempname.c, time_r.c: * timegm.c, tmpfile-safer.c, unlinkdir.c, userspec.c, utime.c: * utimecmp.c, utimens.c, version-etc-fsf.c, version-etc.c: * xalloc-die.c, xgetcwd.c, xgethostname.c, xmalloc.c: * xmemcoll.c, xnanosleep.c, xreadlink.c, xstrtod.c: * xstrtoimax.c, xstrtol.c, xstrtoumax.c, yesno.c: Likewise.
Bruno Haible caf80066 2006-07-29T14:38:53 setenv.c comes from gettext / libiconv again.
Karl Berry 183b57c6 2006-03-22T22:08:04 sync from coreutils
Jim Meyering 31589505 2006-02-27T06:37:59 undo last change -- this file is sync'd from gettext
Jim Meyering da326536 2006-02-24T10:09:59 Normalize inclusion of `config.h'.
Paul Eggert 267a39ba 2005-05-14T06:03:57 *** empty log message ***
Karl Berry 2a3f7e67 2005-03-02T14:56:43 sync (copyright years)
Paul Eggert a62be9f4 2004-08-07T00:09:38 Merge from coreutils.
Bruno Haible cca613ab 2004-01-20T17:05:34 Use allocsa instead of alloca.
Paul Eggert fa9635f2 2003-09-12T18:24:51 Remove K&R cruft.
Bruno Haible 7dd7a67c 2003-09-10T14:16:32 Assume ANSI C <string.h>, <stdlib.h>.
Paul Eggert 757bd39e 2003-07-14T22:44:04 Update gettext source files from gettext automatically, using srclist-update.
Bruno Haible 48dbf2c1 2003-01-10T21:06:49 Make it possibly to simply write: #include <alloca.h>.
Bruno Haible 336175d0 2002-12-11T20:31:00 setenv and unsetenv.
Jim Meyering d349992d 2000-07-09T07:22:43 update copyright date
Jim Meyering 783c1624 1996-07-15T03:56:06 indent cpp-directives
Jim Meyering aa9ba4a2 1996-04-01T04:29:28 (unsetenv): unprotoize.
Jim Meyering 692c4b6e 1996-03-31T23:30:43 .