changeset 13031:1887a0e2d01f

setenv: Tweaks.
author Bruno Haible <bruno@clisp.org>
date Sun, 21 Mar 2010 23:22:33 +0100
parents e947b6ae7d08
children 64faceabf217
files ChangeLog doc/posix-functions/setenv.texi m4/setenv.m4
diffstat 3 files changed, 10 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2010-03-21  Bruno Haible  <bruno@clisp.org>
+
+	setenv: Tweaks.
+	* m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Include necessary headers in
+	the test program.
+	* doc/posix-functions/setenv.texi: Update platforms list.
+
 2010-03-21  Bruno Haible  <bruno@clisp.org>
 
 	New module 'unlockpt'.
--- a/doc/posix-functions/setenv.texi
+++ b/doc/posix-functions/setenv.texi
@@ -14,7 +14,7 @@
 @item
 On some platforms, this function does not fail with @samp{EINVAL} when
 passed an empty string or a string containing @samp{=}:
-FreeBSD 6.0, NetBSD 1.6, OpenBSD 3.8, Cygwin 1.5.x.
+MacOS X 10.5, FreeBSD 6.0, NetBSD 1.6, OpenBSD 3.8, Cygwin 1.5.x.
 @item
 On some platforms, this function removes a leading @samp{=} from the
 value argument:
--- a/m4/setenv.m4
+++ b/m4/setenv.m4
@@ -1,4 +1,4 @@
-# setenv.m4 serial 15
+# setenv.m4 serial 16
 dnl Copyright (C) 2001-2004, 2006-2010 Free Software Foundation, Inc.
 dnl This file is free software; the Free Software Foundation
 dnl gives unlimited permission to copy and/or distribute it,
@@ -25,6 +25,7 @@
       [AC_RUN_IFELSE([AC_LANG_PROGRAM([[
        #include <stdlib.h>
        #include <errno.h>
+       #include <string.h>
       ]], [[
        if (setenv ("", "", 0) != -1) return 1;
        if (errno != EINVAL) return 2;