httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marc Slemko <>
Subject [PATCH] sys/stat.h and sys/types.h again
Date Sat, 01 Nov 1997 01:33:26 GMT
In general, sys/types.h _needs_ to be included before sys/stat.h.  BSD
weenies have this thing about never daring include a header file more than
once if they can help it, which results in you having to include
sys/types.h before a lot of things.  Some FreeBSD 2.1.x installations have
this... "feature", along with some other boxes.

I would suggest the below change.  The whole conf.h needs a major cleanup. 
(yes, Sameer has suggested two patches but no one went for them... 
something like this _is_ necessary) 

Index: conf.h
RCS file: /export/home/cvs/apachen/src/main/conf.h,v
retrieving revision 1.150
diff -u -r1.150 conf.h
--- conf.h	1997/10/25 01:52:45	1.150
+++ conf.h	1997/11/01 01:20:56
@@ -57,11 +57,10 @@
+#ifdef WIN32
 /* Have to include sys/stat.h before ../os/win32/os.h so we can override
-stat() properly */
+ * stat() properly */
 #include <sys/stat.h>
-#ifdef WIN32
 #include "../os/win32/os.h"
 #include "os.h"
@@ -720,6 +719,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
+#ifndef WIN32
+#include <sys/stat.h>
 #include <ctype.h>
 #if !defined(MPE) && !defined(WIN32)
 #include <sys/file.h>

View raw message