aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-common.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/c-common.c')
-rw-r--r--gcc/c-common.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/gcc/c-common.c b/gcc/c-common.c
index d59386d..cb6b78f 100644
--- a/gcc/c-common.c
+++ b/gcc/c-common.c
@@ -2021,24 +2021,24 @@ status_warning VPARAMS ((int *status, const char *msgid, ...))
va_list ap;
diagnostic_context dc;
- if (status)
- *status = 1;
- else
- {
- VA_START (ap, msgid);
+ VA_START (ap, msgid);
#ifndef ANSI_PROTOTYPES
- status = va_arg (ap, int *);
- msgid = va_arg (ap, const char *);
+ status = va_arg (ap, int *);
+ msgid = va_arg (ap, const char *);
#endif
+ if (status)
+ *status = 1;
+ else
+ {
/* This duplicates the warning function behavior. */
set_diagnostic_context
(&dc, msgid, &ap, input_filename, lineno, /* warn = */ 1);
report_diagnostic (&dc);
-
- va_end (ap);
}
+
+ va_end (ap);
}
/* Variables used by the checking of $ operand number formats. */