From: Paul Eggert Date: Wed, 6 Apr 2011 04:58:58 +0000 (-0700) Subject: doprnt, error, and verror are not printf-compatible. X-Git-Tag: emacs-pretest-24.0.90~104^2~275^2~394^2 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=b69769da408705e40929b793d79d3bfe6a3a5a48;p=emacs.git doprnt, error, and verror are not printf-compatible. --- diff --git a/src/ChangeLog b/src/ChangeLog index 788defbbf60..965af3cb888 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -6,8 +6,7 @@ * menu.c (Fx_popup_menu): Don't assume error_name lacks printf formats. - * lisp.h (message, message_nolog, doprnt, error, verror, fatal): - Mark as printf-like functions. + * lisp.h (message, message_nolog, fatal): Mark as printf-like. * xdisp.c (vmessage): Mark as a printf-like function. diff --git a/src/lisp.h b/src/lisp.h index 016ed15bdba..f3016d521d1 100644 --- a/src/lisp.h +++ b/src/lisp.h @@ -2782,8 +2782,7 @@ extern void float_to_string (char *, double); extern void syms_of_print (void); /* Defined in doprnt.c */ -extern EMACS_INT doprnt (char *, int, const char *, const char *, va_list) - ATTRIBUTE_FORMAT_PRINTF (3, 0); +extern EMACS_INT doprnt (char *, int, const char *, const char *, va_list); extern Lisp_Object Qvariable_documentation, Qstandard_input; extern Lisp_Object Qbackquote, Qcomma, Qcomma_at, Qcomma_dot, Qfunction; @@ -2874,9 +2873,8 @@ extern Lisp_Object internal_condition_case_n (Lisp_Object (*) (size_t, Lisp_Obje extern void specbind (Lisp_Object, Lisp_Object); extern void record_unwind_protect (Lisp_Object (*) (Lisp_Object), Lisp_Object); extern Lisp_Object unbind_to (int, Lisp_Object); -extern void error (const char *, ...) NO_RETURN ATTRIBUTE_FORMAT_PRINTF (1, 2); -extern void verror (const char *, va_list) - NO_RETURN ATTRIBUTE_FORMAT_PRINTF (1, 0); +extern void error (const char *, ...) NO_RETURN; +extern void verror (const char *, va_list) NO_RETURN; extern void do_autoload (Lisp_Object, Lisp_Object); extern Lisp_Object un_autoload (Lisp_Object); EXFUN (Ffetch_bytecode, 1); diff --git a/src/term.c b/src/term.c index d4e5faf01c8..39c9592e28f 100644 --- a/src/term.c +++ b/src/term.c @@ -86,7 +86,7 @@ static void dissociate_if_controlling_tty (int fd); static void delete_tty (struct terminal *); static void maybe_fatal (int must_succeed, struct terminal *terminal, const char *str1, const char *str2, ...) - NO_RETURN ATTRIBUTE_FORMAT_PRINTF (3, 5) ATTRIBUTE_FORMAT_PRINTF (4, 5); + NO_RETURN ATTRIBUTE_FORMAT_PRINTF (4, 5); static void vfatal (const char *str, va_list ap) NO_RETURN ATTRIBUTE_FORMAT_PRINTF (1, 0);