From owner-svn-src-all@FreeBSD.ORG Mon Dec 8 21:04:25 2008 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0FEAC106564A; Mon, 8 Dec 2008 21:04:25 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id F028B8FC17; Mon, 8 Dec 2008 21:04:24 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id mB8L4OpU070678; Mon, 8 Dec 2008 21:04:24 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id mB8L4OW0070671; Mon, 8 Dec 2008 21:04:24 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <200812082104.mB8L4OW0070671@svn.freebsd.org> From: Konstantin Belousov Date: Mon, 8 Dec 2008 21:04:24 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r185777 - in head: gnu/usr.bin/cc/libiberty gnu/usr.bin/sort include kerberos5/include lib/bind/bind lib/libmagic usr.bin/file X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Dec 2008 21:04:25 -0000 Author: kib Date: Mon Dec 8 21:04:24 2008 New Revision: 185777 URL: http://svn.freebsd.org/changeset/base/185777 Log: Add strndup(3) prototype to string.h. This change was erronously ommitted from the r185690, and attempt to simply add the prototype to string.h has revealed that several contributed programs defined local prototypes for strndup(), controlled by autoconfed config.h. So, manually change #undef HAVE_STRNDUP to #define HAVE_STRNDUP 1. Next import of the corresponding program would regenerate config.h, overriding the changes in this commit. No objections from: kan Modified: head/gnu/usr.bin/cc/libiberty/config.h head/gnu/usr.bin/sort/config.h head/include/string.h head/kerberos5/include/config.h head/lib/bind/bind/port_after.h head/lib/libmagic/config.h head/usr.bin/file/config.h Modified: head/gnu/usr.bin/cc/libiberty/config.h ============================================================================== --- head/gnu/usr.bin/cc/libiberty/config.h Mon Dec 8 20:53:27 2008 (r185776) +++ head/gnu/usr.bin/cc/libiberty/config.h Mon Dec 8 21:04:24 2008 (r185777) @@ -235,7 +235,7 @@ #define HAVE_STRNCASECMP 1 /* Define to 1 if you have the `strndup' function. */ -/* #undef HAVE_STRNDUP */ +#define HAVE_STRNDUP 1 /* Define to 1 if you have the `strrchr' function. */ #define HAVE_STRRCHR 1 Modified: head/gnu/usr.bin/sort/config.h ============================================================================== --- head/gnu/usr.bin/sort/config.h Mon Dec 8 20:53:27 2008 (r185776) +++ head/gnu/usr.bin/sort/config.h Mon Dec 8 21:04:24 2008 (r185777) @@ -759,7 +759,7 @@ #define HAVE_STRNCASECMP 1 /* Define to 1 if you have the `strndup' function. */ -/* #undef HAVE_STRNDUP */ +#define HAVE_STRNDUP 1 /* Define to 1 if you have the `strpbrk' function. */ #define HAVE_STRPBRK 1 Modified: head/include/string.h ============================================================================== --- head/include/string.h Mon Dec 8 20:53:27 2008 (r185776) +++ head/include/string.h Mon Dec 8 21:04:24 2008 (r185777) @@ -96,6 +96,7 @@ char *strncat(char * __restrict, const c int strncmp(const char *, const char *, size_t) __pure; char *strncpy(char * __restrict, const char * __restrict, size_t); #if __BSD_VISIBLE +char *strndup(const char *, size_t); char *strnstr(const char *, const char *, size_t) __pure; #endif char *strpbrk(const char *, const char *) __pure; Modified: head/kerberos5/include/config.h ============================================================================== --- head/kerberos5/include/config.h Mon Dec 8 20:53:27 2008 (r185776) +++ head/kerberos5/include/config.h Mon Dec 8 21:04:24 2008 (r185777) @@ -785,7 +785,7 @@ static /**/const char *const rcsid[] = { #define HAVE_STRNCASECMP 1 /* Define if you have the function `strndup'. */ -/* #undef HAVE_STRNDUP */ +#define HAVE_STRNDUP 1 /* Define if you have the function `strnlen'. */ /* #undef HAVE_STRNLEN */ Modified: head/lib/bind/bind/port_after.h ============================================================================== --- head/lib/bind/bind/port_after.h Mon Dec 8 20:53:27 2008 (r185776) +++ head/lib/bind/bind/port_after.h Mon Dec 8 21:04:24 2008 (r185777) @@ -30,7 +30,7 @@ #undef HAS_IN_ADDR6 #define HAVE_SOCKADDR_STORAGE 1 #undef NEED_GETTIMEOFDAY -#undef HAVE_STRNDUP +#define HAVE_STRNDUP 1 #undef USE_FIONBIO_IOCTL #undef USE_SYSERROR_LIST #undef INNETGR_ARGS Modified: head/lib/libmagic/config.h ============================================================================== --- head/lib/libmagic/config.h Mon Dec 8 20:53:27 2008 (r185776) +++ head/lib/libmagic/config.h Mon Dec 8 21:04:24 2008 (r185777) @@ -77,7 +77,7 @@ #define HAVE_STRING_H 1 /* Define to 1 if you have the `strndup' function. */ -/* #undef HAVE_STRNDUP */ +#define HAVE_STRNDUP 1 /* Define to 1 if you have the `strtof' function. */ #define HAVE_STRTOF 1 Modified: head/usr.bin/file/config.h ============================================================================== --- head/usr.bin/file/config.h Mon Dec 8 20:53:27 2008 (r185776) +++ head/usr.bin/file/config.h Mon Dec 8 21:04:24 2008 (r185777) @@ -77,7 +77,7 @@ #define HAVE_STRING_H 1 /* Define to 1 if you have the `strndup' function. */ -/* #undef HAVE_STRNDUP */ +#define HAVE_STRNDUP 1 /* Define to 1 if you have the `strtof' function. */ #define HAVE_STRTOF 1