httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ralf S. Engelschall" <...@engelschall.com>
Subject Re: [PATCH] Resolve BUILD warnings under ULTRIX/mips (take 4)
Date Tue, 14 Apr 1998 12:32:16 GMT

In article <199804111512.LAA18293@siam.gensym> Ben Hyde wrote:

> A fourth version of this patch, necessary due to name changes.
>[...]

Ok, I've tried to create a different and more clean variant of this patch for
you which avoids bristling the sources with os-stuff for just one braindead
platform.  Please try it out, Ben, and give feedback if it works for Ultrix.
As Knuth said: "Beware of bugs in the above code; I have only proved it
correct, not tried it."
                                       Ralf S. Engelschall
                                       rse@engelschall.com
                                       www.engelschall.com
Index: os/unix/os.c
===================================================================
RCS file: /e/apache/REPOS/apache-1.3/src/os/unix/os.c,v
retrieving revision 1.9
diff -u -r1.9 os.c
--- os.c	1998/04/13 18:05:19	1.9
+++ os.c	1998/04/14 12:27:51
@@ -13,6 +13,17 @@
 extern void ap_is_not_here(void);
 void ap_is_not_here(void) {}
 
+/* 
+ * Some patches for braindead Ultrix platforms
+ */
+#ifdef ULTRIX
+#undef fdopen
+FILE *ap_os_fdopen(int filedes, char *mode)
+{
+	return fdopen(filedes, mode);
+}
+#endif
+
 /*
  *  Abstraction layer for loading
  *  Apache modules under run-time via 
Index: os/unix/os.h
===================================================================
RCS file: /e/apache/REPOS/apache-1.3/src/os/unix/os.h,v
retrieving revision 1.21
diff -u -r1.21 os.h
--- os.h	1998/04/13 18:05:19	1.21
+++ os.h	1998/04/14 12:28:08
@@ -79,6 +79,15 @@
 extern int ap_os_is_path_absolute(const char *f);
 #endif
 
+/* 
+ * Some patches for braindead Ultrix platforms
+ */
+#ifdef ULTRIX
+extern char *mktemp(char *template);
+FILE *ap_os_fdopen(int, char *);
+#define fdopen(d,m) ap_os_fdopen((d), (char *)(m))
+#endif
+
 /*
  *  Abstraction layer for loading
  *  Apache modules under run-time via 
Index: modules/standard/mod_autoindex.c
===================================================================
RCS file: /e/apache/REPOS/apache-1.3/src/modules/standard/mod_autoindex.c,v
retrieving revision 1.74
diff -u -r1.74 mod_autoindex.c
--- mod_autoindex.c	1998/04/13 18:05:15	1.74
+++ mod_autoindex.c	1998/04/14 12:25:57
@@ -1113,12 +1113,8 @@
 	    p = p->next;
 	}
 
-#ifdef ULTRIX_BRAIN_DEATH
-	qsort((void *) ar, num_ent, sizeof(struct ent *), (int (*)) dsortf);
-#else
 	qsort((void *) ar, num_ent, sizeof(struct ent *),
 	          (int (*)(const void *, const void *)) dsortf);
-#endif
     }
     output_directories(ar, num_ent, autoindex_conf, r, autoindex_opts, keyid,
 		       direction);

Mime
View raw message