diff options
author | Marcus Brinkmann <marcus@gnu.org> | 2003-05-07 13:42:14 +0000 |
---|---|---|
committer | Marcus Brinkmann <marcus@gnu.org> | 2003-05-07 13:42:14 +0000 |
commit | 8e833469cbe0f6f2ba26d23f7e11540a75071e9d (patch) | |
tree | 22ae0d9ef531c86664505920af2a1b4dd12a8559 | |
parent | e3cbee8a4eac20433701b41a9e678750ec4e496e (diff) |
2003-05-07 Ognyan Kulev <ogi@fmi.uni-sofia.bg>
* strfcns.c: #include <stdarg.h> instead of <varargs.h>.
(strbuild): Use <stdarg.h>-style for handling variable argument
list.
* load.c: Don't #include <varargs.h>.
-rw-r--r-- | serverboot/load.c | 1 | ||||
-rw-r--r-- | serverboot/strfcns.c | 9 |
2 files changed, 4 insertions, 6 deletions
diff --git a/serverboot/load.c b/serverboot/load.c index e95a64d7..aa481943 100644 --- a/serverboot/load.c +++ b/serverboot/load.c @@ -27,7 +27,6 @@ #include <stddef.h> #include <assert.h> #include <mach/mach_interface.h> -#include <varargs.h> #include "mach-exec.h" #include "../boot/boot_script.h" diff --git a/serverboot/strfcns.c b/serverboot/strfcns.c index 82a76728..cbead7e4 100644 --- a/serverboot/strfcns.c +++ b/serverboot/strfcns.c @@ -27,7 +27,7 @@ * Character subroutines */ -#include <varargs.h> +#include <stdarg.h> #define EXPORT_BOOLEAN #include <mach/boolean.h> @@ -40,21 +40,20 @@ */ /*VARARGS1*/ char * -strbuild(dest, va_alist) - register char * dest; - va_dcl +strbuild(char *dest, ...) { va_list argptr; register char * src; register int c; - va_start(argptr); + va_start(argptr, dest); while ((src = va_arg(argptr, char *)) != (char *)0) { while ((c = *src++) != '\0') *dest++ = c; } *dest = '\0'; + va_end(argptr); return (dest); } |