Assume <string.h> exists,
authorBruno Haible <bruno@clisp.org>
Tue, 19 Aug 2003 11:32:28 +0000 (11:32 +0000)
committerBruno Haible <bruno@clisp.org>
Tue, 19 Aug 2003 11:32:28 +0000 (11:32 +0000)
lib/ChangeLog
lib/xstrdup.c
m4/ChangeLog
m4/xalloc.m4

index 7d2a512..ad78dc7 100644 (file)
@@ -1,3 +1,7 @@
+2003-08-19  Bruno Haible  <bruno@clisp.org>
+
+       * xstrdup.c: Assume <string.h> exists.
+
 2003-08-18  Jim Meyering  <jim@meyering.net>
 
        * setenv.h: Indent nested cpp directive.
index cb1efa8..1182c59 100644 (file)
@@ -1,5 +1,5 @@
 /* xstrdup.c -- copy a string with out of memory checking
-   Copyright (C) 1990, 1996, 1998, 2001 Free Software Foundation, Inc.
+   Copyright (C) 1990, 1996, 1998, 2001, 2003 Free Software Foundation, Inc.
 
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
 # include <config.h>
 #endif
 
-#if STDC_HEADERS || HAVE_STRING_H
-# include <string.h>
-#else
-# include <strings.h>
-#endif
-
-#include <sys/types.h>
-
+/* Specification.  */
 #include "xalloc.h"
 
+#include <string.h>
+
 /* Return a newly allocated copy of STRING.  */
 
 char *
index 2fcbade..30b315a 100644 (file)
@@ -1,3 +1,7 @@
+2003-08-19  Bruno Haible  <bruno@clisp.org>
+
+       * xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any more.
+
 2003-08-17  Simon Josefsson  <jas@extundo.com>
 
        * argp.m4: New file.
index 1826bdc..5dcb730 100644 (file)
@@ -1,5 +1,5 @@
-# xalloc.m4 serial 1
-dnl Copyright (C) 2002 Free Software Foundation, Inc.
+# xalloc.m4 serial 2
+dnl Copyright (C) 2002-2003 Free Software Foundation, Inc.
 dnl This file is free software, distributed under the terms of the GNU
 dnl General Public License.  As a special exception to the GNU General
 dnl Public License, this file may be distributed as part of a program
@@ -21,6 +21,5 @@ AC_DEFUN([gl_PREREQ_XMALLOC], [
 
 # Prerequisites of lib/xstrdup.c.
 AC_DEFUN([gl_PREREQ_XSTRDUP], [
-  AC_REQUIRE([AC_HEADER_STDC])
-  AC_CHECK_HEADERS_ONCE(string.h)
+  :
 ])