3 * concat.c -- concatenate a variable number (minimum of 1)
4 * of strings in managed memory
8 * This code is Copyright (c) 2002, by the authors of nmh. See the
9 * COPYRIGHT file in the root directory of the nmh distribution for
10 * complete copyright information.
17 concat (char *s1, ...)
23 len = strlen (s1) + 1;
25 while ((cp = va_arg(list, char *)))
29 if (!(dp = sp = malloc(len)))
30 adios (NULL, "unable to allocate string storage");
35 while ((cp = va_arg (list, char *)))