aboutsummaryrefslogtreecommitdiff
path: root/gcc/gcc.c
diff options
context:
space:
mode:
authorDoug Evans <dje@gnu.org>1996-06-13 14:45:59 +0000
committerDoug Evans <dje@gnu.org>1996-06-13 14:45:59 +0000
commitfe628d093252209a458c8604c6980ee69580683c (patch)
tree0b47a64897ff8f652c1bc5b686a3f976143cb892 /gcc/gcc.c
parent745466f2f559ca95a59e3108c82f6e6ac2031b66 (diff)
downloadgcc-fe628d093252209a458c8604c6980ee69580683c.zip
gcc-fe628d093252209a458c8604c6980ee69580683c.tar.gz
gcc-fe628d093252209a458c8604c6980ee69580683c.tar.bz2
* gcc.c (pfatal_pexecute): Delete code to check errno < sys_nerr.
From-SVN: r12281
Diffstat (limited to 'gcc/gcc.c')
-rw-r--r--gcc/gcc.c16
1 files changed, 2 insertions, 14 deletions
diff --git a/gcc/gcc.c b/gcc/gcc.c
index eba5f07..f13803d 100644
--- a/gcc/gcc.c
+++ b/gcc/gcc.c
@@ -973,8 +973,8 @@ char *
my_strerror(e)
int e;
{
-
#ifdef HAVE_STRERROR
+
return strerror(e);
#else
@@ -4557,18 +4557,6 @@ pfatal_pexecute (errmsg_fmt, errmsg_arg)
char *errmsg_fmt;
char *errmsg_arg;
{
- char buf[30];
- char *s;
-
- /* ??? Why doesn't my_strerror handle this? */
- if (errno < sys_nerr)
- s = my_strerror (errno);
- else
- {
- sprintf (buf, "unknown error %d", errno);
- s = buf;
- }
-
if (errmsg_arg)
{
/* Space for trailing '\0' is in %s. */
@@ -4577,7 +4565,7 @@ pfatal_pexecute (errmsg_fmt, errmsg_arg)
errmsg_fmt = msg;
}
- fatal ("%s: %s", errmsg_fmt, s);
+ fatal ("%s: %s", errmsg_fmt, my_strerror (errno));
}
/* More 'friendly' abort that prints the line and file.