summaryrefslogtreecommitdiff
path: root/lib/libc/gen/stringlist.c
diff options
context:
space:
mode:
authorBruce Evans <bde@FreeBSD.org>2001-11-11 02:48:09 +0000
committerBruce Evans <bde@FreeBSD.org>2001-11-11 02:48:09 +0000
commitac8e56a7f941dd3a327bfebbcc6568d05d184989 (patch)
tree9f56244d965dec1345589fb1aa8b7b147549c0dd /lib/libc/gen/stringlist.c
parent7f78280b081fd4f24869dfe97310aa6ab1086a75 (diff)
Notes
Diffstat (limited to 'lib/libc/gen/stringlist.c')
-rw-r--r--lib/libc/gen/stringlist.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/libc/gen/stringlist.c b/lib/libc/gen/stringlist.c
index bb749191edac..abe4e00975f3 100644
--- a/lib/libc/gen/stringlist.c
+++ b/lib/libc/gen/stringlist.c
@@ -31,9 +31,14 @@
* SUCH DAMAGE.
*/
+#if 0
#if defined(LIBC_SCCS) && !defined(lint)
static char *rcsid = "$NetBSD: stringlist.c,v 1.2 1997/01/17 07:26:20 lukem Exp $";
#endif /* LIBC_SCCS and not lint */
+#endif
+
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <stdio.h>
#include <string.h>
@@ -51,13 +56,13 @@ sl_init()
{
StringList *sl = malloc(sizeof(StringList));
if (sl == NULL)
- err(1, "stringlist: %m");
+ _err(1, "stringlist: %m");
sl->sl_cur = 0;
sl->sl_max = _SL_CHUNKSIZE;
sl->sl_str = malloc(sl->sl_max * sizeof(char *));
if (sl->sl_str == NULL)
- err(1, "stringlist: %m");
+ _err(1, "stringlist: %m");
return sl;
}
@@ -74,7 +79,7 @@ sl_add(sl, name)
sl->sl_max += _SL_CHUNKSIZE;
sl->sl_str = reallocf(sl->sl_str, sl->sl_max * sizeof(char *));
if (sl->sl_str == NULL)
- err(1, "stringlist: %m");
+ _err(1, "stringlist: %m");
}
sl->sl_str[sl->sl_cur++] = name;
}