You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by John Bley <jb...@acpub.duke.edu> on 1999/03/28 11:57:49 UTC

[PATCH] Two tiny casts

Fix two little cast issues.  My compilers don't care too much, perhaps 
some do though.

-- 
John Bley - jbb6@acpub.duke.edu
Duke '99 - English/Computer Science
  Since English is a mess, it maps well onto the problem space,
  which is also a mess, which we call reality.     - Larry Wall

diff -Burp apache-1.3/src/main/http_config.c apache-1.3-patched/src/main/http_config.c
--- apache-1.3/src/main/http_config.c	Wed Mar 10 09:12:31 1999
+++ apache-1.3-patched/src/main/http_config.c	Sun Mar 28 04:16:47 1999
@@ -314,7 +314,7 @@ static void build_method_shortcuts(void)
 
     if (method_ptrs) {
 	/* free up any previous set of method_ptrs */
-	free(method_ptrs);
+	free((void *)method_ptrs);
     }
 
     /* first we count how many functions we have */
@@ -326,7 +326,8 @@ static void build_method_shortcuts(void)
 	    }
 	}
     }
-    method_ptrs = malloc((how_many_ptrs + NMETHODS) * sizeof(handler_func));
+    method_ptrs = (handler_func *) malloc((how_many_ptrs + NMETHODS) * 
+	sizeof(handler_func));
     if (method_ptrs == NULL) {
 	fprintf(stderr, "Ouch!  Out of memory in build_method_shortcuts()!\n");
     }