perl-modperl-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject cvs commit: modperl-2.0/src/modules/perl mod_perl.c mod_perl.h modperl_cmd.c
Date Wed, 16 Apr 2003 03:03:36 GMT
stas        2003/04/15 20:03:36

  Modified:    xs/tables/current/ModPerl FunctionTable.pm
               src/modules/perl mod_perl.c mod_perl.h modperl_cmd.c
  Log:
  to avoid a need for special tests and workaround simplify modperl_run not
  to receive any arguments and use the globally stored pconf and server_rec
  records internally.
  
  Revision  Changes    Path
  1.112     +0 -8      modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm
  
  Index: FunctionTable.pm
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/xs/tables/current/ModPerl/FunctionTable.pm,v
  retrieving revision 1.111
  retrieving revision 1.112
  diff -u -r1.111 -r1.112
  --- FunctionTable.pm	15 Apr 2003 08:39:52 -0000	1.111
  +++ FunctionTable.pm	16 Apr 2003 03:03:35 -0000	1.112
  @@ -3929,14 +3929,6 @@
       'return_type' => 'int',
       'name' => 'modperl_run',
       'args' => [
  -      {
  -        'type' => 'apr_pool_t *',
  -        'name' => 'p'
  -      },
  -      {
  -        'type' => 'server_rec *',
  -        'name' => 's'
  -      }
       ]
     },
     {
  
  
  
  1.169     +5 -21     modperl-2.0/src/modules/perl/mod_perl.c
  
  Index: mod_perl.c
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/src/modules/perl/mod_perl.c,v
  retrieving revision 1.168
  retrieving revision 1.169
  diff -u -r1.168 -r1.169
  --- mod_perl.c	7 Apr 2003 01:56:54 -0000	1.168
  +++ mod_perl.c	16 Apr 2003 03:03:35 -0000	1.169
  @@ -331,20 +331,6 @@
       modperl_config_srv_t *base_scfg;
       PerlInterpreter *base_perl;
   
  -    /* get the real base server when invoked from vhost.
  -     *
  -     * without doing it segfaults when the first PerlLoadModule
  -     * appears inside vhost, e.g.:
  -     *     <VirtualHost _default_:8535>
  -     *         PerlLoadModule Foo
  -     *     </VirtualHost> 
  -     * an arrangement which is unfortunately hard to automate with our
  -     * test suite, but see test TestDirective::perlloadmodule6
  -     */
  -    if (base_server->is_virtual) {
  -        base_server = modperl_global_get_server_rec();
  -    }
  -
       base_scfg = modperl_config_srv_get(base_server);
   
       MP_TRACE_d_do(MpSrv_dump_flags(base_scfg,
  @@ -505,14 +491,12 @@
    * if we need to init earlier than post_config,
    * e.g. <Perl> sections or directive handlers.
    */
  -/*
  - * XXX: this probably won't work well if called from a
  - * vhost rather than the base config if modperl_hook_init
  - * hasn't been run first from the base config.
  - */
  -int modperl_run(apr_pool_t *p, server_rec *s)
  +int modperl_run(void)
   {
  -    return modperl_hook_init(p, NULL, NULL, s);
  +    return modperl_hook_init(modperl_global_get_pconf(),
  +                             NULL,
  +                             NULL,
  +                             modperl_global_get_server_rec());
   }
   
   int modperl_is_running(void)
  
  
  
  1.58      +1 -1      modperl-2.0/src/modules/perl/mod_perl.h
  
  Index: mod_perl.h
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/src/modules/perl/mod_perl.h,v
  retrieving revision 1.57
  retrieving revision 1.58
  diff -u -r1.57 -r1.58
  --- mod_perl.h	7 Apr 2003 05:01:48 -0000	1.57
  +++ mod_perl.h	16 Apr 2003 03:03:35 -0000	1.58
  @@ -73,7 +73,7 @@
                          server_rec *base_server);
   void modperl_init(server_rec *s, apr_pool_t *p);
   void modperl_init_globals(server_rec *s, apr_pool_t *pconf);
  -int modperl_run(apr_pool_t *p, server_rec *s);
  +int modperl_run(void);
   int modperl_is_running(void);
   int modperl_hook_init(apr_pool_t *pconf, apr_pool_t *plog, 
                         apr_pool_t *ptemp, server_rec *s);
  
  
  
  1.47      +2 -2      modperl-2.0/src/modules/perl/modperl_cmd.c
  
  Index: modperl_cmd.c
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_cmd.c,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -r1.46 -r1.47
  --- modperl_cmd.c	14 Apr 2003 23:36:55 -0000	1.46
  +++ modperl_cmd.c	16 Apr 2003 03:03:35 -0000	1.47
  @@ -370,7 +370,7 @@
       }
   
       /* we must init earlier than normal */
  -    modperl_run(p, s);
  +    modperl_run();
   
       if (modperl_init_vhost(s, p, NULL) != OK) {
           return "init mod_perl vhost failed";
  @@ -496,7 +496,7 @@
       MP_TRACE_d(MP_FUNC, "PerlLoadModule %s\n", arg);
   
       /* we must init earlier than normal */
  -    modperl_run(p, s);
  +    modperl_run();
   
       if ((errmsg = modperl_cmd_modules(parms, mconfig, arg))) {
           return errmsg;
  
  
  

Mime
View raw message