This patch changes the use of varargs.h to stdarg.h as
required by modern versions of GCC. Niels Breet
This commit is contained in:
parent
ea208aca00
commit
3fa7901070
@ -5,7 +5,7 @@
|
|||||||
** This is used to print out error messages and exit
|
** This is used to print out error messages and exit
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <varargs.h>
|
#include <stdarg.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
@ -19,15 +19,14 @@
|
|||||||
|
|
||||||
/*VARARGS*/
|
/*VARARGS*/
|
||||||
void
|
void
|
||||||
halt(va_alist)
|
halt(const char *path, ...)
|
||||||
va_dcl
|
|
||||||
{
|
{
|
||||||
va_list arg_ptr;
|
va_list arg_ptr;
|
||||||
char *format,
|
char *format,
|
||||||
*pstr;
|
*pstr;
|
||||||
void (*sig_func) ();
|
void (*sig_func) ();
|
||||||
|
|
||||||
va_start(arg_ptr);
|
va_start(arg_ptr, path);
|
||||||
format = va_arg(arg_ptr, char *);
|
format = va_arg(arg_ptr, char *);
|
||||||
if (strncmp(format, "PERROR", 6) != 0)
|
if (strncmp(format, "PERROR", 6) != 0)
|
||||||
vfprintf(stderr, format, arg_ptr);
|
vfprintf(stderr, format, arg_ptr);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user