diff options
author | Jim Meyering <jim@meyering.net> | 2003-07-23 06:39:44 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2003-07-23 06:39:44 +0000 |
commit | 8d69e13ee51f618bdf85f3933134d859677b7adf (patch) | |
tree | 96c2e969b7c522285fa8d42943a5b42441c69938 /src | |
parent | b220480e9d2a0f595b839ac0c7b50e6c739b8bb4 (diff) | |
download | coreutils-8d69e13ee51f618bdf85f3933134d859677b7adf.tar.xz |
Include xstrndup.h.
(xstrndup): Remove function, now that it's been factored out into
it's own file.
Diffstat (limited to 'src')
-rw-r--r-- | src/dircolors.c | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/src/dircolors.c b/src/dircolors.c index 97e34628e..5d18f098c 100644 --- a/src/dircolors.c +++ b/src/dircolors.c @@ -1,6 +1,6 @@ /* dircolors - output commands to set the LS_COLOR environment variable - Copyright (C) 1994, 1995, 1997, 1998, 1999, 2000, 2001, 2002 H. Peter Anvin - Copyright (C) 1996-2000 Free Software Foundation, Inc. + Copyright (C) 1996-2003 Free Software Foundation, Inc. + Copyright (C) 1994, 1995, 1997, 1998, 1999, 2000 H. Peter Anvin 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 @@ -31,6 +31,7 @@ #include "getline.h" #include "obstack.h" #include "quote.h" +#include "xstrndup.h" /* The official name of this program (e.g., no `g' prefix). */ #define PROGRAM_NAME "dircolors" @@ -123,15 +124,6 @@ For details on the format of these files, run `dircolors --print-database'.\n\ exit (status == 0 ? EXIT_SUCCESS : EXIT_FAILURE); } -static void * -xstrndup (const char *s, size_t n) -{ - char *new = strndup (s, n); - if (new == NULL) - xalloc_die (); - return new; -} - /* If the SHELL environment variable is set to `csh' or `tcsh,' assume C shell. Else Bourne shell. */ |