cvs commit: p5ee/App-Context/lib App.pm

[email protected] (Stephen Adkins)
Newsgroups perl.cvs.p5ee
Message-ID <[email protected]>
cvsuser     05/10/12 06:53:35

  Modified:    App-Context/lib App.pm
  Log:
  fixed a trace leak (return without sub_exit())
  
  Revision  Changes    Path
  1.17      +6 -2      p5ee/App-Context/lib/App.pm
  
  Index: App.pm
  ===================================================================
  RCS file: /cvs/public/p5ee/App-Context/lib/App.pm,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -r1.16 -r1.17
  --- App.pm	27 Sep 2005 16:53:23 -0000	1.16
  +++ App.pm	12 Oct 2005 13:53:35 -0000	1.17
  @@ -497,7 +497,11 @@
   sub new {
       &App::sub_entry if ($App::trace);
       my $self = shift;
  -    return $self->context() if ($#_ == -1);
  +    if ($#_ == -1) {
  +        my $context = $self->context();
  +        &App::sub_exit($context) if ($App::trace);
  +        return($context);
  +    }
       my $class = shift;
       if ($class =~ /^([A-Za-z0-9:_]+)$/) {
           $class = $1;  # untaint the $class
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.