diff options
author | Zack Weinberg <zack@codesourcery.com> | 2003-05-13 18:06:52 +0000 |
---|---|---|
committer | Zack Weinberg <zack@gcc.gnu.org> | 2003-05-13 18:06:52 +0000 |
commit | fa6ef81367f0c24ec0b04e753313cdb023e10217 (patch) | |
tree | fd24969394b3b9dffb1cc037cebd35f54276e5b8 /gcc/ggc-page.c | |
parent | 3bec3c0c9cadc98f39f7072cb77a1c1b90ada59b (diff) | |
download | gcc-fa6ef81367f0c24ec0b04e753313cdb023e10217.zip gcc-fa6ef81367f0c24ec0b04e753313cdb023e10217.tar.gz gcc-fa6ef81367f0c24ec0b04e753313cdb023e10217.tar.bz2 |
diagnostic.c (output_format): Add support for %m.
* diagnostic.c (output_format): Add support for %m.
(output_printf, output_verbatim, diagnostic_set_info,
verbatim): Set err_no field of the text_info structure being
initialized.
(fatal_io_error): Delete function.
* diagnostic.h (text_info): Add err_no field.
* toplev.h (fatal_io_error): Delete prototype.
* c-opts.c, c-pch.c, dwarfout.c, ggc-common.c, ggc-page.c, graph.c
* toplev.c, config/mips/mips.c, config/rs6000/host-darwin.c
* f/com.c, java/jcf-parse.c, java/jcf-write.c, java/lex.c
* objc/objc-act.c: Replace all calls to fatal_io_error with
calls to fatal_error; add ": %m" to the end of all the affected
error messages.
From-SVN: r66769
Diffstat (limited to 'gcc/ggc-page.c')
-rw-r--r-- | gcc/ggc-page.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/gcc/ggc-page.c b/gcc/ggc-page.c index 569e519..51ea7f0 100644 --- a/gcc/ggc-page.c +++ b/gcc/ggc-page.c @@ -1954,20 +1954,20 @@ ggc_pch_write_object (d, f, x, newx, size) } if (fwrite (x, size, 1, f) != 1) - fatal_io_error ("can't write PCH file"); + fatal_error ("can't write PCH file: %m"); /* In the current implementation, SIZE is always equal to OBJECT_SIZE (order) and so the fseek is never executed. */ if (size != OBJECT_SIZE (order) && fseek (f, OBJECT_SIZE (order) - size, SEEK_CUR) != 0) - fatal_io_error ("can't write PCH file"); + fatal_error ("can't write PCH file: %m"); d->written[order]++; if (d->written[order] == d->d.totals[order] && fseek (f, ROUND_UP_VALUE (d->d.totals[order] * OBJECT_SIZE (order), G.pagesize), SEEK_CUR) != 0) - fatal_io_error ("can't write PCH file"); + fatal_error ("can't write PCH file: %m"); } void @@ -1976,7 +1976,7 @@ ggc_pch_finish (d, f) FILE *f; { if (fwrite (&d->d, sizeof (d->d), 1, f) != 1) - fatal_io_error ("can't write PCH file"); + fatal_error ("can't write PCH file: %m"); free (d); } @@ -2068,7 +2068,7 @@ ggc_pch_read (f, addr) /* Allocate the appropriate page-table entries for the pages read from the PCH file. */ if (fread (&d, sizeof (d), 1, f) != 1) - fatal_io_error ("can't read PCH file"); + fatal_error ("can't read PCH file: %m"); for (i = 0; i < NUM_ORDERS; i++) { |