summaryrefslogtreecommitdiff
path: root/devel/bmake/files/str.c
diff options
context:
space:
mode:
authorjoerg <joerg@pkgsrc.org>2008-11-11 14:28:21 +0000
committerjoerg <joerg@pkgsrc.org>2008-11-11 14:28:21 +0000
commit0c12e37e3073ec4f5ac022f03ae124d9a5799379 (patch)
tree06f6cda6bc543e835e2936c69e60f9070d755a89 /devel/bmake/files/str.c
parent769645f8708288a32de4868bc43933c70b1cee91 (diff)
downloadpkgsrc-0c12e37e3073ec4f5ac022f03ae124d9a5799379.tar.gz
Update to bmake 20081101 snapshot. The more important changes are:
- portability fixes for putenv - man page updates - fix processing of .END with -j - fix some segmentation faults on parse errors - debug output goes to stderr by default - first round of fixes for A/UX - fix crashes on long lines - faster VarQuote - fix use of ?= when the LHS contains variable references
Diffstat (limited to 'devel/bmake/files/str.c')
-rw-r--r--devel/bmake/files/str.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/devel/bmake/files/str.c b/devel/bmake/files/str.c
index 04f27863bfe..dec066292c2 100644
--- a/devel/bmake/files/str.c
+++ b/devel/bmake/files/str.c
@@ -1,4 +1,4 @@
-/* $NetBSD: str.c,v 1.1.1.2 2008/03/09 19:39:34 joerg Exp $ */
+/* $NetBSD: str.c,v 1.1.1.3 2008/11/11 14:28:30 joerg Exp $ */
/*-
* Copyright (c) 1988, 1989, 1990, 1993
@@ -69,14 +69,14 @@
*/
#ifndef MAKE_NATIVE
-static char rcsid[] = "$NetBSD: str.c,v 1.1.1.2 2008/03/09 19:39:34 joerg Exp $";
+static char rcsid[] = "$NetBSD: str.c,v 1.1.1.3 2008/11/11 14:28:30 joerg Exp $";
#else
#include <sys/cdefs.h>
#ifndef lint
#if 0
static char sccsid[] = "@(#)str.c 5.8 (Berkeley) 6/1/90";
#else
-__RCSID("$NetBSD: str.c,v 1.1.1.2 2008/03/09 19:39:34 joerg Exp $");
+__RCSID("$NetBSD: str.c,v 1.1.1.3 2008/11/11 14:28:30 joerg Exp $");
#endif
#endif /* not lint */
#endif
@@ -102,7 +102,7 @@ str_concat(const char *s1, const char *s2, int flags)
len2 = strlen(s2);
/* allocate length plus separator plus EOS */
- result = emalloc((u_int)(len1 + len2 + 2));
+ result = bmake_malloc((u_int)(len1 + len2 + 2));
/* copy first string into place */
memcpy(result, s1, len1);
@@ -145,7 +145,7 @@ brk_string(const char *str, int *store_argc, Boolean expand, char **buffer)
const char *p;
int len;
int argmax = 50, curlen = 0;
- char **argv = emalloc((argmax + 1) * sizeof(char *));
+ char **argv = bmake_malloc((argmax + 1) * sizeof(char *));
/* skip leading space chars. */
for (; *str == ' ' || *str == '\t'; ++str)
@@ -153,7 +153,7 @@ brk_string(const char *str, int *store_argc, Boolean expand, char **buffer)
/* allocate room for a copy of the string */
if ((len = strlen(str) + 1) > curlen)
- *buffer = emalloc(curlen = len);
+ *buffer = bmake_malloc(curlen = len);
/*
* copy the string; at the same time, parse backslashes,
@@ -206,7 +206,7 @@ brk_string(const char *str, int *store_argc, Boolean expand, char **buffer)
*t++ = '\0';
if (argc == argmax) {
argmax *= 2; /* ramp up fast */
- argv = (char **)erealloc(argv,
+ argv = (char **)bmake_realloc(argv,
(argmax + 1) * sizeof(char *));
}
argv[argc++] = start;