2004-05-24  Ulrich Drepper  <drepper@redhat.com>

	* manual/string.texi (Copying and Concatenation): Fixed second
	concat example.
	Reported by Fabian Pietsch <fabian@zzznowman.dyndns.org>.
This commit is contained in:
Ulrich Drepper 2004-05-24 18:12:23 +00:00
parent 75c827b5e1
commit 623281e06d
2 changed files with 9 additions and 3 deletions

View File

@ -1,3 +1,9 @@
2004-05-24 Ulrich Drepper <drepper@redhat.com>
* manual/string.texi (Copying and Concatenation): Fixed second
concat example.
Reported by Fabian Pietsch <fabian@zzznowman.dyndns.org>.
2004-05-23 Ulrich Drepper <drepper@redhat.com>
* malloc/obstack.c: Don't allow linking with _obstack.

View File

@ -880,13 +880,13 @@ concat (const char *str, @dots{})
va_list ap;
size_t allocated = 100;
char *result = (char *) malloc (allocated);
char *wp;
if (allocated != NULL)
if (result != NULL)
@{
char *newp;
char *wp;
va_start (ap, atr);
va_start (ap, str);
wp = result;
for (s = str; s != NULL; s = va_arg (ap, const char *))