perl-modperl-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ge...@apache.org
Subject cvs commit: modperl-2.0/xs/Apache/Module Apache__Module.h
Date Fri, 30 May 2003 13:39:44 GMT
geoff       2003/05/30 06:39:44

  Modified:    xs/Apache/Module Apache__Module.h
  Log:
  sorry, committed a change in progress.  really sorry.
  
  Revision  Changes    Path
  1.10      +37 -1     modperl-2.0/xs/Apache/Module/Apache__Module.h
  
  Index: Apache__Module.h
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/xs/Apache/Module/Apache__Module.h,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- Apache__Module.h	30 May 2003 13:37:19 -0000	1.9
  +++ Apache__Module.h	30 May 2003 13:39:44 -0000	1.10
  @@ -44,5 +44,41 @@
                                                       server_rec *s,
                                                       ap_conf_vector_t *v)
   {
  -    return modperl_get_config(aTHX_ pmodule, s, v);
  +    MP_dSCFG(s);
  +    module *modp;
  +    const char *name;
  +    void *ptr;
  +    PTR_TBL_t *table;
  +    SV *obj;
  +
  +    if (!v) {
  +        v = s->module_config;
  +    }
  +
  +    if (SvROK(pmodule)) {
  +        name = SvCLASS(pmodule);
  +    }
  +    else {
  +        STRLEN n_a;
  +        name = SvPV(pmodule, n_a);
  +    }
  +
  +    if (!(scfg->modules &&
  +          (modp = apr_hash_get(scfg->modules, name, APR_HASH_KEY_STRING)))) {
  +        return &PL_sv_undef;
  +    }
  +
  +    if (!(ptr = ap_get_module_config(v, modp))) {
  +        return &PL_sv_undef;
  +    }
  +
  +    if (!(table = modperl_module_config_table_get(aTHX_ FALSE))) {
  +        return &PL_sv_undef;
  +    }
  +
  +    if (!(obj = modperl_svptr_table_fetch(aTHX_ table, ptr))) {
  +        return &PL_sv_undef;
  +    }
  +
  +    return SvREFCNT_inc(obj);
   }
  
  
  

Mime
View raw message