[PATCH/libiberty] Add missing <sys/types.h> in unlink-if-ordinary.c
Mark Kettenis
mark.kettenis@xs4all.nl
Sun Mar 27 18:48:00 GMT 2005
One really shouldn't include <sys/stat.h> without <sys/types.h> on
BSD-derived systems. On most modern BSD's it is brought in by
<unistd.h> but vax-dec-ultrix4.0 doesn't have one, so things break.
The attached patch fixes that.
ok?
Mark
Index: ChangeLog
from Mark Kettenis <kettenis@gnu.org>
* unlink-if-ordinary.c: Include <sys/types.h>.
Index: unlink-if-ordinary.c
===================================================================
RCS file: /cvs/src/src/libiberty/unlink-if-ordinary.c,v
retrieving revision 1.1
diff -u -p -r1.1 unlink-if-ordinary.c
--- unlink-if-ordinary.c 1 Mar 2005 14:33:00 -0000 1.1
+++ unlink-if-ordinary.c 26 Mar 2005 14:18:20 -0000
@@ -39,6 +39,8 @@ was made to unlink the file because it i
#include "config.h"
#endif
+#include <sys/types.h>
+
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
More information about the Binutils
mailing list