Better debugging
This commit is contained in:
parent
0515fe51fd
commit
5799815c2e
|
@ -61,7 +61,12 @@ sub DESTROY {
|
|||
|
||||
sub AUTOLOAD {
|
||||
my $self = shift;
|
||||
my $class = ref($self) || Fatal("$self not object");
|
||||
my $class = ref($self);
|
||||
if ( !$class ) {
|
||||
my ( $caller, undef, $line ) = caller;
|
||||
Fatal("$self not object from $caller:$line");
|
||||
}
|
||||
|
||||
my $name = $AUTOLOAD;
|
||||
$name =~ s/.*://;
|
||||
if ( exists($self->{$name}) ) {
|
||||
|
|
|
@ -32,8 +32,6 @@ require ZoneMinder::Control;
|
|||
|
||||
our @ISA = qw(ZoneMinder::Control);
|
||||
|
||||
our $VERSION = $ZoneMinder::Base::VERSION;
|
||||
|
||||
# ==========================================================================
|
||||
#
|
||||
# Sony Network Camera Control Protocol
|
||||
|
@ -50,7 +48,7 @@ sub open {
|
|||
|
||||
use LWP::UserAgent;
|
||||
$self->{ua} = LWP::UserAgent->new;
|
||||
$self->{ua}->agent( 'ZoneMinder Control Agent/'.$VERSION );
|
||||
$self->{ua}->agent('ZoneMinder Control Agent/'.$ZoneMinder::Base::VERSION);
|
||||
|
||||
$self->{state} = 'open';
|
||||
}
|
||||
|
@ -102,9 +100,8 @@ sub moveConLeft {
|
|||
|
||||
sub moveConRight {
|
||||
my $self = shift;
|
||||
Debug( "Move Right" );
|
||||
|
||||
my $cmd = "/command/ptzf.cgi?Move=right,8,1";
|
||||
Debug('Move Right');
|
||||
my $cmd = '/command/ptzf.cgi?Move=right,8,1';
|
||||
$self->sendCmd($cmd);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue