fix warnings
authorDobrica Pavlinusic <dpavlin@rot13.org>
Sun, 28 Oct 2007 13:05:01 +0000 (13:05 +0000)
committerDobrica Pavlinusic <dpavlin@rot13.org>
Sun, 28 Oct 2007 13:05:01 +0000 (13:05 +0000)
git-svn-id: https://perl-cwmp.googlecode.com/svn/trunk@169 836a5e1a-633d-0410-964b-294494ad4392

lib/CWMP/Session.pm
lib/CWMP/Store.pm

index b128f66..4df8709 100644 (file)
@@ -147,7 +147,7 @@ sub process_request {
 
        $sock->send( "Set-Cookie: ID=" . $state->{ID} . "; path=/\r\n" ) if ( $state->{ID} );
        
 
        $sock->send( "Set-Cookie: ID=" . $state->{ID} . "; path=/\r\n" ) if ( $state->{ID} );
        
-       my $xml = '';
+       $xml = '';
 
        if ( my $dispatch = $state->{_dispatch} ) {
                $xml = $self->dispatch( $dispatch );
 
        if ( my $dispatch = $state->{_dispatch} ) {
                $xml = $self->dispatch( $dispatch );
index 37c3a84..3b61924 100644 (file)
@@ -46,6 +46,9 @@ sub new {
 
        $self->current_store->open( @_ );
 
 
        $self->current_store->open( @_ );
 
+       # so that we don't have to check if it's defined
+       $self->debug( 0 ) unless $self->debug;
+
        return $self;
 }
 
        return $self;
 }