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/xs/tables/current/ModPerl FunctionTable.pm
Date Tue, 01 Jun 2004 23:33:50 GMT
stas        2004/06/01 16:33:50

  Modified:    xs/Apache/Filter Apache__Filter.h
               xs/maps  apache_functions.map
               xs/tables/current/ModPerl FunctionTable.pm
  Log:
  fflush(), get_brigade() and pass_brigade() now throw exceptions if
  called in the void context
  
  Revision  Changes    Path
  1.39      +42 -4     modperl-2.0/xs/Apache/Filter/Apache__Filter.h
  
  Index: Apache__Filter.h
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/xs/Apache/Filter/Apache__Filter.h,v
  retrieving revision 1.38
  retrieving revision 1.39
  diff -u -u -r1.38 -r1.39
  --- Apache__Filter.h	1 Jun 2004 20:18:02 -0000	1.38
  +++ Apache__Filter.h	1 Jun 2004 23:33:50 -0000	1.39
  @@ -292,9 +292,47 @@
   }
   
   static MP_INLINE
  -void mpxs_Apache__Filter_fflush(pTHX_ ap_filter_t *filter,
  -                                apr_bucket_brigade *brigade)
  +apr_status_t mpxs_Apache__Filter_fflush(pTHX_ ap_filter_t *filter,
  +                                        apr_bucket_brigade *brigade)
   {
  -    MP_RUN_CROAK(ap_fflush(filter, brigade),
  -                 "Apache::Filter::fflush");
  +    apr_status_t rc = ap_fflush(filter, brigade);
  +    /* if users don't bother to check the success, do it on their
  +     * behalf */
  +    if (GIMME_V == G_VOID && rc != APR_SUCCESS) {
  +        modperl_croak(aTHX_ rc, "Apache::Filter::fflush");
  +    }
  +
  +    return rc;
  +}
  +
  +static MP_INLINE
  +apr_status_t mpxs_Apache__Filter_get_brigade(pTHX_
  +                                             ap_filter_t *f,
  +                                             apr_bucket_brigade *bb,
  +                                             ap_input_mode_t mode,
  +                                             apr_read_type_e block,
  +                                             apr_off_t readbytes)
  +{
  +    apr_status_t rc = ap_get_brigade(f, bb, mode, block, readbytes);
  +    /* if users don't bother to check the success, do it on their
  +     * behalf */
  +    if (GIMME_V == G_VOID && rc != APR_SUCCESS) {
  +        modperl_croak(aTHX_ rc, "Apache::Filter::get_brigade");
  +    }
  +
  +    return rc;
  +}
  +
  +static MP_INLINE
  +apr_status_t mpxs_Apache__Filter_pass_brigade(pTHX_ ap_filter_t *f,
  +                                              apr_bucket_brigade *bb)
  +{
  +    apr_status_t rc = ap_pass_brigade(f, bb);
  +    /* if users don't bother to check the success, do it on their
  +     * behalf */
  +    if (GIMME_V == G_VOID && rc != APR_SUCCESS) {
  +        modperl_croak(aTHX_ rc, "Apache::Filter::pass_brigade");
  +    }
  +
  +    return rc;
   }
  
  
  
  1.80      +5 -3      modperl-2.0/xs/maps/apache_functions.map
  
  Index: apache_functions.map
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/xs/maps/apache_functions.map,v
  retrieving revision 1.79
  retrieving revision 1.80
  diff -u -u -r1.79 -r1.80
  --- apache_functions.map	1 Jun 2004 20:18:02 -0000	1.79
  +++ apache_functions.map	1 Jun 2004 23:33:50 -0000	1.80
  @@ -221,11 +221,13 @@
   -ap_add_output_filter_handle
   -ap_get_output_filter_handle
   >ap_add_ouput_filters_by_type
  - ap_get_brigade | | \
  -               filter, bucket, mode=AP_MODE_READBYTES, \
  +-ap_get_brigade
  + mpxs_Apache__Filter_get_brigade | | \
  +               f, bb, mode=AP_MODE_READBYTES, \
                  block=APR_BLOCK_READ, \
                  readbytes=8192
  - ap_pass_brigade
  +- ap_pass_brigade
  + mpxs_Apache__Filter_pass_brigade
   !ap_register_input_filter
   !ap_register_output_filter
   -ap_remove_output_filter
  
  
  
  1.161     +50 -2     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.160
  retrieving revision 1.161
  diff -u -u -r1.160 -r1.161
  --- FunctionTable.pm	1 Jun 2004 20:18:02 -0000	1.160
  +++ FunctionTable.pm	1 Jun 2004 23:33:50 -0000	1.161
  @@ -2,7 +2,7 @@
   
   # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
   # ! WARNING: generated by ModPerl::ParseSource/0.01
  -# !          Mon May 31 12:36:08 2004
  +# !          Tue Jun  1 15:51:17 2004
   # !          do NOT edit, any changes will be lost !
   # !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
   
  @@ -5798,7 +5798,7 @@
       ]
     },
     {
  -    'return_type' => 'void',
  +    'return_type' => 'apr_status_t',
       'name' => 'mpxs_Apache__Filter_fflush',
       'args' => [
         {
  @@ -5812,6 +5812,54 @@
         {
           'type' => 'apr_bucket_brigade *',
           'name' => 'brigade'
  +      }
  +    ]
  +  },
  +  {
  +    'return_type' => 'apr_status_t',
  +    'name' => 'mpxs_Apache__Filter_get_brigade',
  +    'args' => [
  +      {
  +        'type' => 'PerlInterpreter *',
  +        'name' => 'my_perl'
  +      },
  +      {
  +        'type' => 'ap_filter_t *',
  +        'name' => 'f'
  +      },
  +      {
  +        'type' => 'apr_bucket_brigade *',
  +        'name' => 'bb'
  +      },
  +      {
  +        'type' => 'ap_input_mode_t',
  +        'name' => 'mode'
  +      },
  +      {
  +        'type' => 'apr_read_type_e',
  +        'name' => 'block'
  +      },
  +      {
  +        'type' => 'apr_off_t',
  +        'name' => 'readbytes'
  +      }
  +    ]
  +  },
  +  {
  +    'return_type' => 'apr_status_t',
  +    'name' => 'mpxs_Apache__Filter_pass_brigade',
  +    'args' => [
  +      {
  +        'type' => 'PerlInterpreter *',
  +        'name' => 'my_perl'
  +      },
  +      {
  +        'type' => 'ap_filter_t *',
  +        'name' => 'f'
  +      },
  +      {
  +        'type' => 'apr_bucket_brigade *',
  +        'name' => 'bb'
         }
       ]
     },
  
  
  

Mime
View raw message