}
\f
+FILE *
+xfdopen (int fd, char const *mode)
+{
+ FILE *res = fdopen (fd, mode);
+ if (! res)
+ error (EXIT_FAILURE, get_errno (),
+ // On a separate line to please the "unmarked_diagnostics"
+ // syntax-check.
+ "fdopen");
+ return res;
+}
+
/*------------------------------------------------------------------.
| Compute ALL_BUT_EXT, ALL_BUT_TAB_EXT and output files extensions. |
`------------------------------------------------------------------*/
bool conflict = false;
if (STREQ (*file_name, grammar_file))
{
- complain (_("refusing to overwrite the input file %s"),
+ complain (NULL, complaint, _("refusing to overwrite the input file %s"),
quote (*file_name));
conflict = true;
}
for (i = 0; i < file_names_count; i++)
if (STREQ (file_names[i], *file_name))
{
- warn (_("conflicting outputs to file %s"),
- quote (*file_name));
+ complain (NULL, Wother, _("conflicting outputs to file %s"),
+ quote (*file_name));
conflict = true;
}
}