Make varargs usage consistent with the rest of the code.

This commit is contained in:
Todd C. Miller
2005-03-11 01:57:44 +00:00
parent 7362b7e981
commit e7dcda7920
2 changed files with 6 additions and 12 deletions

View File

@@ -174,7 +174,9 @@ int
#ifdef __STDC__
easprintf(char **ret, const char *fmt, ...)
#else
easprintf(va_alist)
easprintf(ret, fmt, va_alist)
char **ret;
const char *fmt;
va_dcl
#endif
{
@@ -183,12 +185,7 @@ easprintf(va_alist)
#ifdef __STDC__
va_start(ap, fmt);
#else
char **ret;
const char *fmt;
va_start(ap);
ret = va_arg(ap, char **);
fmt = va_arg(ap, const char *);
#endif
len = vasprintf(ret, fmt, ap);
va_end(ap);

View File

@@ -337,7 +337,9 @@ void
#ifdef __STDC__
log_error(int flags, const char *fmt, ...)
#else
log_error(va_alist)
log_error(flags, fmt, va_alist)
int flags;
const char *fmt;
va_dcl
#endif
{
@@ -348,12 +350,7 @@ log_error(va_alist)
#ifdef __STDC__
va_start(ap, fmt);
#else
int flags;
const char *fmt;
va_start(ap);
flags = va_arg(ap, int);
fmt = va_arg(ap, const char *);
#endif
/* Become root if we are not already to avoid user control */