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/ModPerl-Registry/lib/ModPerl RegistryCooker.pm
Date Wed, 02 Jun 2004 22:47:24 GMT
stas        2004/06/02 15:47:24

  Modified:    .        Changes
               ModPerl-Registry/lib/ModPerl RegistryCooker.pm
  Log:
  fix a bug in Registry handlers, where the same error was logged twice
  and potentially a wrong error code returned
  
  Revision  Changes    Path
  1.386     +3 -0      modperl-2.0/Changes
  
  Index: Changes
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/Changes,v
  retrieving revision 1.385
  retrieving revision 1.386
  diff -u -u -r1.385 -r1.386
  --- Changes	2 Jun 2004 21:35:58 -0000	1.385
  +++ Changes	2 Jun 2004 22:47:24 -0000	1.386
  @@ -12,6 +12,9 @@
   
   =item 1.99_15-dev
   
  +fix a bug in Registry handlers, where the same error was logged twice
  +and potentially a wrong error code returned [Stas]
  +
   Apache::RequestIO: print(), printf(), puts(), write(), rflush() throw
   an exception on failure [Stas]
   
  
  
  
  1.49      +12 -6     modperl-2.0/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm
  
  Index: RegistryCooker.pm
  ===================================================================
  RCS file: /home/cvs/modperl-2.0/ModPerl-Registry/lib/ModPerl/RegistryCooker.pm,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -u -r1.48 -r1.49
  --- RegistryCooker.pm	9 May 2004 21:01:47 -0000	1.48
  +++ RegistryCooker.pm	2 Jun 2004 22:47:24 -0000	1.49
  @@ -204,14 +204,20 @@
           # log script's execution errors
           $rc = $self->error_check;
   
  -        ModPerl::Global::special_list_call(END => $package);
  +        {
  +            # there might be no END blocks to call, so $@ will be not
  +            # reset
  +            local $@;
  +            ModPerl::Global::special_list_call(END => $package);
   
  -        # log script's END blocks execution errors
  -        my $new_rc = $self->error_check;
  +            # log script's END blocks execution errors
  +            my $new_rc = $self->error_check;
  +
  +            # use the END blocks return status if the script's execution
  +            # was successful
  +            $rc = $new_rc if $rc == Apache::OK;
  +        }
   
  -        # use the END blocks return status if the script's execution
  -        # was successful
  -        $rc = $new_rc if $rc != Apache::OK;
       }
   
       if ($self->should_reset_inc_hash) {
  
  
  

Mime
View raw message