httpd-apreq-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From j...@apache.org
Subject cvs commit: httpd-apreq-2/glue/perl/xsbuilder apreq_xs_tables.h
Date Tue, 03 Aug 2004 20:40:45 GMT
joes        2004/08/03 13:40:45

  Modified:    glue/perl/xsbuilder apreq_xs_tables.h
  Log:
  Taint cleanups: can't use SvPOK on tainted variable, and object magic always exists so there's
no need for the conditional.
  
  Revision  Changes    Path
  1.32      +4 -10     httpd-apreq-2/glue/perl/xsbuilder/apreq_xs_tables.h
  
  Index: apreq_xs_tables.h
  ===================================================================
  RCS file: /home/cvs/httpd-apreq-2/glue/perl/xsbuilder/apreq_xs_tables.h,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- apreq_xs_tables.h	3 Aug 2004 18:07:58 -0000	1.31
  +++ apreq_xs_tables.h	3 Aug 2004 20:40:45 -0000	1.32
  @@ -265,14 +265,8 @@
       sv = ST(0);                                                         \
       obj = apreq_xs_find_obj(aTHX_ sv, #attr);                           \
       mg = mg_find(obj, PERL_MAGIC_ext);                                  \
  -    if (mg != NULL) {                                                   \
  -        d.parent = mg->mg_obj;                                          \
  -        d.pkg = mg->mg_len > 0 ? mg->mg_ptr : subclass;                 \
  -    }                                                                   \
  -    else {                                                              \
  -        d.parent = obj;                                                 \
  -        d.pkg = subclass;                                               \
  -    }                                                                   \
  +    d.parent = mg->mg_obj;                                              \
  +    d.pkg = mg->mg_len > 0 ? mg->mg_ptr : subclass;                     \
       env = (void *)SvIVX(d.parent);                                      \
       d.env = env;                                                        \
                                                                           \
  @@ -330,8 +324,8 @@
       apr_table_entry_t *te;                                      \
       void *env;                                                  \
                                                                   \
  -    if (items != 2 || !SvROK(ST(0)) || !SvPOK(ST(1)))           \
  -        Perl_croak(aTHX_ "Usage: $table->get($key)");           \
  +    if (items != 2 || !SvROK(ST(0)) || !SvOK(ST(1)))            \
  +        Perl_croak(aTHX_ "Usage: $table->FETCH($key)");         \
                                                                   \
       sv  = ST(0);                                                \
       obj = apreq_xs_find_obj(aTHX_ sv, #attr);                   \
  
  
  

Mime
View raw message