diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2007-03-01 21:24:55 +0000 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2007-03-01 21:24:55 +0000 |
commit | c7857d5835743de62405964797a38f6e1adfb3b1 (patch) | |
tree | 337b8e4ffe7fd841cc2598e3160f2478eb86ce62 | |
parent | 359a6e0fc608dcca9372a68c771ef1cf56169ac0 (diff) | |
download | gnulib-c7857d5835743de62405964797a38f6e1adfb3b1.tar.gz |
Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
<http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
* doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
as another example.
* lib/time_.h: Fix misspelling.
* m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
Require gl_HEADER_TIME_H_DEFAULTS.
* m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
* m4/time_r.m4 (gl_TIME_R): Likewise.
* m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
-rw-r--r-- | ChangeLog | 13 | ||||
-rw-r--r-- | doc/gnulib-tool.texi | 5 | ||||
-rw-r--r-- | lib/time_.h | 2 | ||||
-rw-r--r-- | m4/nanosleep.m4 | 3 | ||||
-rw-r--r-- | m4/strptime.m4 | 3 | ||||
-rw-r--r-- | m4/time_r.m4 | 3 | ||||
-rw-r--r-- | m4/timegm.m4 | 3 |
7 files changed, 26 insertions, 6 deletions
@@ -1,3 +1,16 @@ +2007-03-01 Paul Eggert <eggert@cs.ucla.edu> + + Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in + <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>. + * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS + as another example. + * lib/time_.h: Fix misspelling. + * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): + Require gl_HEADER_TIME_H_DEFAULTS. + * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise. + * m4/time_r.m4 (gl_TIME_R): Likewise. + * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise. + 2007-03-01 Bruno Haible <bruno@clisp.org> * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC. diff --git a/doc/gnulib-tool.texi b/doc/gnulib-tool.texi index d5db08e5cd..cb37964a54 100644 --- a/doc/gnulib-tool.texi +++ b/doc/gnulib-tool.texi @@ -232,8 +232,9 @@ use of @code{strdup}. In the usual case where Autoconf is creating a @file{config.h} file, you should include @file{config.h} first, before any other include file. That way, for example, if @file{config.h} defines -@samp{restrict} to be the empty string on a pre-C99 host, the -definition is consistent for all include files. +@samp{restrict} to be the empty string on a pre-C99 host, or a macro +like @samp{_FILE_OFFSET_BITS} that affects the layout of data +structures, the definition is consistent for all include files. You should include Gnulib-provided headers before system headers, so that Gnulib-provided headers can adjust how a system header diff --git a/lib/time_.h b/lib/time_.h index 7403270874..5467d3dc88 100644 --- a/lib/time_.h +++ b/lib/time_.h @@ -86,7 +86,7 @@ char *strptime (char const *restrict __buf, char const *restrict __format, time_t timegm (struct tm *__tm); #endif -/* Encourage applications to avoid unsafe functions that can overrrun +/* Encourage applications to avoid unsafe functions that can overrun buffers when given outlandish struct tm values. Portable applications should use strftime (or even sprintf) instead. */ # if GNULIB_PORTCHECK diff --git a/m4/nanosleep.m4 b/m4/nanosleep.m4 index a03c37cd8a..a3a6814042 100644 --- a/m4/nanosleep.m4 +++ b/m4/nanosleep.m4 @@ -1,4 +1,4 @@ -#serial 21 +#serial 22 dnl From Jim Meyering. dnl Check for the nanosleep function. @@ -17,6 +17,7 @@ AC_DEFUN([gl_FUNC_NANOSLEEP], dnl Persuade glibc and Solaris <time.h> to declare nanosleep. AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) + AC_REQUIRE([gl_HEADER_TIME_H_DEFAULTS]) AC_REQUIRE([gl_CLOCK_TIME]) AC_CHECK_HEADERS_ONCE(sys/time.h) diff --git a/m4/strptime.m4 b/m4/strptime.m4 index 5f919984d2..060f000021 100644 --- a/m4/strptime.m4 +++ b/m4/strptime.m4 @@ -1,4 +1,4 @@ -# strptime.m4 serial 3 +# strptime.m4 serial 4 dnl Copyright (C) 2007 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -6,6 +6,7 @@ dnl with or without modifications, as long as this notice is preserved. AC_DEFUN([gl_FUNC_STRPTIME], [ + AC_REQUIRE([gl_HEADER_TIME_H_DEFAULTS]) AC_REQUIRE([AC_C_RESTRICT]) AC_REPLACE_FUNCS(strptime) AC_REQUIRE([gl_TM_GMTOFF]) diff --git a/m4/time_r.m4 b/m4/time_r.m4 index a4e016f819..dbb6396607 100644 --- a/m4/time_r.m4 +++ b/m4/time_r.m4 @@ -9,7 +9,10 @@ dnl Written by Paul Eggert. AC_DEFUN([gl_TIME_R], [ + dnl Persuade glibc and Solaris <time.h> to declare localtime_r. AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS]) + + AC_REQUIRE([gl_HEADER_TIME_H_DEFAULTS]) AC_REQUIRE([AC_C_RESTRICT]) AC_CACHE_CHECK([whether localtime_r is compatible with its POSIX signature], diff --git a/m4/timegm.m4 b/m4/timegm.m4 index 51ffd0fb1d..ca903b1afc 100644 --- a/m4/timegm.m4 +++ b/m4/timegm.m4 @@ -1,4 +1,4 @@ -# timegm.m4 serial 4 +# timegm.m4 serial 5 dnl Copyright (C) 2003, 2007 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -6,6 +6,7 @@ dnl with or without modifications, as long as this notice is preserved. AC_DEFUN([gl_FUNC_TIMEGM], [ + AC_REQUIRE([gl_HEADER_TIME_H_DEFAULTS]) AC_REQUIRE([gl_FUNC_MKTIME]) if test $ac_cv_func_working_mktime = no; then # Assume that timegm is buggy if mktime is. |