Skip to content

Commit

Permalink
Set ->message to prevent undef error
Browse files Browse the repository at this point in the history
  • Loading branch information
altaroca committed Jun 18, 2016
1 parent d0e08b3 commit 2157f22
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions onvif/modules/lib/WSDiscovery/TransportUDP.pm
Original file line number Diff line number Diff line change
Expand Up @@ -145,17 +145,18 @@ sub send_receive {
}

if($last_response) {
$self->code();
$self->message();
$self->is_success(1);
$self->status('OK');
$self->set_code();
$self->set_message("");
$self->set_is_success(1);
$self->set_status('OK');
}
else{
$self->code();
$self->message();
$self->is_success(0);
$self->status('TIMEOUT');
$self->set_code();
$self->set_message("Timed out waiting for response");
$self->set_is_success(0);
$self->set_status('TIMEOUT');
}

return $last_response;
}

Expand Down

0 comments on commit 2157f22

Please sign in to comment.