perl-modperl-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From do...@apache.org
Subject cvs commit: modperl-2.0/xs/Apache/Filter Apache__Filter.h
Date Thu, 09 Aug 2001 16:52:51 GMT
dougm       01/08/09 09:52:51

  Modified:    src/modules/perl modperl_bucket.c modperl_filter.c
                        modperl_filter.h
               xs/Apache/Filter Apache__Filter.h
  Log:
  adjust to recent bucket brigade api changes
  
  Revision  Changes    Path
  1.3       +7 -5      modperl-2.0/src/modules/perl/modperl_bucket.c
  
  Index: modperl_bucket.c
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_bucket.c,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- modperl_bucket.c	2001/08/04 18:49:25	1.2
  +++ modperl_bucket.c	2001/08/09 16:52:51	1.3
  @@ -55,7 +55,6 @@
   static const apr_bucket_type_t modperl_bucket_sv_type = {
       "mod_perl SV bucket", 4,
       modperl_bucket_sv_destroy,
  -    modperl_bucket_sv_free,
       modperl_bucket_sv_read,
       apr_bucket_setaside_notimpl,
       apr_bucket_shared_split,
  @@ -67,9 +66,10 @@
                                             SV *sv,
                                             int offset, int len)
   {
  -    modperl_bucket_sv_t *svbucket = 
  -        (modperl_bucket_sv_t *)safemalloc(sizeof(*svbucket));
  +    modperl_bucket_sv_t *svbucket; 
   
  +    Newz(0, svbucket, 1, modperl_bucket_sv_t);
  +
       bucket = apr_bucket_shared_make(bucket, svbucket, offset, offset+len);
   
       /* XXX: need to deal with PerlInterpScope */
  @@ -79,7 +79,7 @@
       svbucket->sv = sv;
   
       if (!bucket) {
  -        safefree(svbucket);
  +        Safefree(svbucket);
           return NULL;
       }
   
  @@ -88,6 +88,8 @@
       MP_TRACE_f(MP_FUNC, "sv=0x%lx, refcnt=%d\n",
                  (unsigned long)sv, SvREFCNT(sv));
   
  +    bucket->free = modperl_bucket_sv_free;
  +
       bucket->type = &modperl_bucket_sv_type;
   
       return bucket;
  @@ -95,7 +97,7 @@
   
   apr_bucket *modperl_bucket_sv_create(pTHX_ SV *sv, int offset, int len)
   {
  -    apr_bucket *bucket = (apr_bucket *)calloc(1, sizeof(*bucket));
  +    apr_bucket *bucket = (apr_bucket *)safemalloc(sizeof(*bucket));
       APR_BUCKET_INIT(bucket);
       return modperl_bucket_sv_make(aTHX_ bucket, sv, offset, len);
   }
  
  
  
  1.23      +2 -2      modperl-2.0/src/modules/perl/modperl_filter.c
  
  Index: modperl_filter.c
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.c,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- modperl_filter.c	2001/07/15 23:42:06	1.22
  +++ modperl_filter.c	2001/08/09 16:52:51	1.23
  @@ -112,7 +112,7 @@
   }
   
   int modperl_run_filter(modperl_filter_t *filter, ap_input_mode_t mode,
  -                       apr_size_t *readbytes)
  +                       apr_off_t *readbytes)
   {
       AV *args = Nullav;
       int status;
  @@ -382,7 +382,7 @@
   apr_status_t modperl_input_filter_handler(ap_filter_t *f,
                                             apr_bucket_brigade *bb,
                                             ap_input_mode_t mode,
  -                                          apr_size_t *readbytes)
  +                                          apr_off_t *readbytes)
   {
       modperl_filter_t *filter;
       int status;
  
  
  
  1.10      +2 -2      modperl-2.0/src/modules/perl/modperl_filter.h
  
  Index: modperl_filter.h
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/src/modules/perl/modperl_filter.h,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- modperl_filter.h	2001/07/15 22:33:48	1.9
  +++ modperl_filter.h	2001/08/09 16:52:51	1.10
  @@ -26,7 +26,7 @@
   modperl_filter_t *modperl_filter_mg_get(pTHX_ SV *obj);
   
   int modperl_run_filter(modperl_filter_t *filter, ap_input_mode_t mode,
  -                       apr_size_t *readbytes);
  +                       apr_off_t *readbytes);
   
   /* output filters */
   apr_status_t modperl_output_filter_handler(ap_filter_t *f,
  @@ -53,7 +53,7 @@
   apr_status_t modperl_input_filter_handler(ap_filter_t *f,
                                             apr_bucket_brigade *bb,
                                             ap_input_mode_t mode,
  -                                          apr_size_t *readbytes);
  +                                          apr_off_t *readbytes);
   
   void modperl_input_filter_register_connection(conn_rec *c);
   
  
  
  
  1.13      +1 -1      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.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- Apache__Filter.h	2001/07/15 22:33:50	1.12
  +++ Apache__Filter.h	2001/08/09 16:52:51	1.13
  @@ -63,7 +63,7 @@
                                           ap_input_mode_t mode,
                                           SV *svreadbytes)
   {
  -    apr_size_t readbytes = svreadbytes ? SvIV(svreadbytes) : 0;
  +    apr_off_t readbytes = svreadbytes ? SvIV(svreadbytes) : 0;
       apr_status_t status = ap_get_brigade(filter, brigade, mode, &readbytes);
   
       if (svreadbytes) {
  
  
  

Mime
View raw message