From: Jason Molenda Date: Thu, 16 Apr 1998 20:14:51 +0000 (+0000) Subject: Thu Apr 16 13:13:24 1998 Jason Molenda (crash@bugshack.cygnus.com) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a17aca4705baf61d56cc41076d85ce38a1da89cd;p=binutils-gdb.git Thu Apr 16 13:13:24 1998 Jason Molenda (crash@bugshack.cygnus.com) * rdi-share/etherdrv.c (EthernetWrite): Use strerror to get error string if in an ANSI C-ish environment. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index aabd63a9859..38e372f259e 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +Thu Apr 16 13:13:24 1998 Jason Molenda (crash@bugshack.cygnus.com) + + * rdi-share/etherdrv.c (EthernetWrite): Use strerror to get + error string if in an ANSI C-ish environment. + Wed Apr 15 18:59:48 1998 Mark Alexander * sparc-tdep.c (SPARC_HAS_FPU): Define. diff --git a/gdb/rdi-share/etherdrv.c b/gdb/rdi-share/etherdrv.c index 46eeaf460bd..58462d44768 100644 --- a/gdb/rdi-share/etherdrv.c +++ b/gdb/rdi-share/etherdrv.c @@ -662,12 +662,17 @@ static int EthernetWrite(DriverCall *dc) #ifdef DEBUG perror("sendto"); #endif + #ifdef COMPILING_ON_WINDOWS panic("ethernet send failure\n"); #else /* might not work for Windows */ panic("ethernet send failure [%s]\n", +#ifdef STDC_HEADERS + strerror(errno)); +#else errno < sys_nerr ? sys_errlist[errno] : "unknown errno"); +#endif /* STDC_HEADERS */ #endif } #ifdef DEBUG