Protoization.

This commit is contained in:
Kevin Buettner 2000-08-29 01:56:59 +00:00
parent f9365b11b5
commit 2935d1c22e
2 changed files with 4 additions and 30 deletions

View File

@ -1,3 +1,7 @@
2000-08-28 Kevin Buettner <kevinb@redhat.com>
* gdbserver/utils.c (error, fatal): Protoize.
2000-08-27 Mark Kettenis <kettenis@gnu.org>
* i386-linux-nat.c (fetch_inferior_registers): Move call to

View File

@ -56,33 +56,14 @@ perror_with_name (char *string)
STRING is the error message, used as a fprintf string,
and ARG is passed as an argument to it. */
#ifdef ANSI_PROTOTYPES
NORETURN void
error (const char *string,...)
#else
void
error (va_alist)
va_dcl
#endif
{
extern jmp_buf toplevel;
va_list args;
#ifdef ANSI_PROTOTYPES
va_start (args, string);
#else
va_start (args);
#endif
fflush (stdout);
#ifdef ANSI_PROTOTYPES
vfprintf (stderr, string, args);
#else
{
char *string1;
string1 = va_arg (args, char *);
vfprintf (stderr, string1, args);
}
#endif
fprintf (stderr, "\n");
longjmp (toplevel, 1);
}
@ -93,21 +74,10 @@ error (va_alist)
/* VARARGS */
NORETURN void
#ifdef ANSI_PROTOTYPES
fatal (char *string,...)
#else
fatal (va_alist)
va_dcl
#endif
{
va_list args;
#ifdef ANSI_PROTOTYPES
va_start (args, string);
#else
char *string;
va_start (args);
string = va_arg (args, char *);
#endif
fprintf (stderr, "gdb: ");
vfprintf (stderr, string, args);
fprintf (stderr, "\n");