httpd-test-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From do...@apache.org
Subject cvs commit: httpd-test/perl-framework/c-modules/list_modules .cvsignore mod_list_modules.c
Date Wed, 21 Nov 2001 00:09:38 GMT
dougm       01/11/20 16:09:38

  Added:       perl-framework/c-modules/list_modules .cvsignore
                        mod_list_modules.c
  Log:
  module to get a list of loaded modules (for mod_info test)
  
  Revision  Changes    Path
  1.1                  httpd-test/perl-framework/c-modules/list_modules/.cvsignore
  
  Index: .cvsignore
  ===================================================================
  Makefile
  .libs
  *.lo
  *.slo
  *.la
  
  
  
  1.1                  httpd-test/perl-framework/c-modules/list_modules/mod_list_modules.c
  
  Index: mod_list_modules.c
  ===================================================================
  #if CONFIG_FOR_HTTPD_TEST
  
  <Location /list_modules>
     SetHandler list_modules
  </Location>
  
  #endif
  
  #define APACHE_HTTPD_TEST_HANDLER list_modules_handler
  
  #define CORE_PRIVATE /* for ap_top_module */
  #include "apache_httpd_test.h"
  
  static int list_modules_handler(request_rec *r)
  {
      module *modp;
  
      if (strcmp(r->handler, "list_modules")) {
          return DECLINED;
      }
      if (r->method_number != M_GET) {
          return DECLINED;
      }
  
  #ifdef APACHE1
  #define ap_top_module top_module
      ap_send_http_header(r);
  #endif
  
      for (modp = ap_top_module; modp; modp = modp->next) {
          ap_rvputs(r, modp->name, "\n", NULL);
      }
  
      return OK;
  }
  
  APACHE_HTTPD_TEST_MODULE(list_modules);
  
  
  
  

Mime
View raw message