Patch: tfformat.c doesn't compile under hpux 10.20
John David Anglin
dave@hiauly1.hia.nrc.ca
Mon Sep 11 09:54:00 GMT 2000
This patch fixes a problem compiling the test program tfformat.c under
hpux 10.20. The include of stdlib.h has been removed because under hpux
it results in the inclusion of stdio.h. The definitions in stdio.h
conflict with those in iostdio.h.
The header stdlib.h was included for `exit'. The single use of exit in
the program has been changed to a return. Tested under hpux and i686
linux.
Dave
--
J. David Anglin dave.anglin@nrc.ca
National Research Council of Canada (613) 990-0752 (FAX: 952-6605)
2000-09-07 J. David Anglin <dave@hiauly1.hia.nrc.ca>
* tfformat.c: Don't include stdlib.h. Use return rather than exit.
--- tfformat.c.orig Tue May 23 15:30:42 2000
+++ tfformat.c Thu Sep 7 21:20:30 2000
@@ -8,8 +8,6 @@
#endif
#endif /* !TEST_LIBIO */
-#include <stdlib.h> /* for exit */
-
/* Tests taken from Cygnus C library. */
typedef struct
@@ -4064,7 +4062,7 @@
point format can provide. So only run it if doubles
are last least 64bits wide. */
if (sizeof (double) < 8)
- exit (0);
+ return 0;
#if defined(__cplusplus) && !defined(TEST_LIBIO)
More information about the Gcc-bugs
mailing list