(fatal): Implement using varargs.
* lisp.h (fatal): Add argument types. (Restore 2005-09-30 change).
+2007-11-22 Dan Nicolaescu <dann@ics.uci.edu>
+
+ * term.c: Include stdarg.h.
+ (fatal): Implement using varargs.
+ * lisp.h (fatal): Add argument types. (Restore 2005-09-30 change).
+
2007-11-21 Stefan Monnier <monnier@iro.umontreal.ca>
* lisp.h (struct Lisp_Buffer_Objfwd): Add a `slottype' field.
/* Defined in term.c */
extern void syms_of_term P_ ((void));
-extern void fatal () NO_RETURN;
+extern void fatal P_ ((const char *msgid, ...)) NO_RETURN;
/* Defined in terminal.c */
extern void syms_of_terminal P_ ((void));
#endif
#include <signal.h>
+#include <stdarg.h>
#include "lisp.h"
#include "termchar.h"
abort ();
}
-/* VARARGS 1 */
void
-fatal (str, arg1, arg2)
- char *str, *arg1, *arg2;
+fatal (const char *str, ...)
{
+ va_list ap;
+ va_start (ap, str);
fprintf (stderr, "emacs: ");
- fprintf (stderr, str, arg1, arg2);
- fprintf (stderr, "\n");
+ vfprintf (stderr, str, ap);
+ va_end (ap);
fflush (stderr);
exit (1);
}