httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Bley <j...@acpub.duke.edu>
Subject Re: [PATCH] module init doesn't seem to be called in mod_so.c
Date Thu, 04 Mar 1999 20:22:27 GMT
On Thu, 4 Mar 1999, Dean Gaudet wrote:

> > I was using cflow to try to comprehend some aspects of Apache (as well as 
> > look for dead code) and noticed that ap_single_module_init wasn't being 
> > called by anything.
> I think it was added for a similar reason, and then we discovered this was
> the wrong way to do it, or something like that.

Ah, yes, I see that now, looking over the archives.  Many thanks.
Well, seeing as absolutely nothing else calls it, it's dead code and 
should be removed.

Patch to remove ap_single_module_init follows.  (Patch against a 
recent CVS snapshot.)  I have no idea if the numbers in 
ApacheCore.def need updating because of that.
-- 
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/ApacheCore.def apache-1.3-patched/src/ApacheCore.def
--- apache-1.3/src/ApacheCore.def	Tue Feb  9 15:12:21 1999
+++ apache-1.3-patched/src/ApacheCore.def	Thu Mar  4 14:58:30 1999
@@ -320,7 +320,6 @@ EXPORTS
 	ap_method_number_of   @313
 	ap_exists_config_define   @314
 	ap_single_module_configure   @315
-	ap_single_module_init   @316
 	ap_make_etag   @317
 	ap_array_pstrcat   @318
 	ap_os_is_filename_valid   @319
diff -Burp apache-1.3/src/include/http_config.h apache-1.3-patched/src/include/http_config.h
--- apache-1.3/src/include/http_config.h	Wed Jan  6 15:12:24 1999
+++ apache-1.3-patched/src/include/http_config.h	Thu Mar  4 14:59:37 1999
@@ -344,7 +344,6 @@ extern API_VAR_EXPORT module **ap_loaded
 /* For mod_so.c... */
 
 void ap_single_module_configure(pool *p, server_rec *s, module *m);
-void ap_single_module_init(pool *p, server_rec *s, module *m);
 
 /* For http_main.c... */
 
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	Mon Feb 22 15:12:37 1999
+++ apache-1.3-patched/src/main/http_config.c	Thu Mar  4 14:59:56 1999
@@ -1492,14 +1492,6 @@ void ap_single_module_configure(pool *p,
                              (*m->create_dir_config)(p, NULL));
 }
 
-void ap_single_module_init(pool *p, server_rec *s, module *m)
-{
-    if (m->init)
-        (*m->init)(s, p);
-    build_method_shortcuts();
-    init_handlers(p);
-}
-
 void ap_init_modules(pool *p, server_rec *s)
 {
     module *m;
diff -Burp apache-1.3/src/support/httpd.exp apache-1.3-patched/src/support/httpd.exp
--- apache-1.3/src/support/httpd.exp	Wed Feb 10 15:12:39 1999
+++ apache-1.3-patched/src/support/httpd.exp	Thu Mar  4 15:00:21 1999
@@ -310,7 +310,6 @@ ap_show_directives
 ap_show_modules
 ap_signal
 ap_single_module_configure
-ap_single_module_init
 ap_size_list_item
 ap_slack
 ap_snprintf



Mime
View raw message