2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-01-31 06:39:11 +00:00

70_ZoneMinder: fixed uninitialized value warnings

git-svn-id: https://svn.fhem.de/fhem/trunk@20459 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
delmar 2019-11-05 18:24:53 +00:00
parent b351956d9b
commit a45cc2cc17
2 changed files with 8 additions and 2 deletions

View File

@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it.
- bugfix: 70_ZoneMinder: fixed uninitialized value warnings
- feature: 74_XiaomiBTLESens: code implementation for ClearGrassSens
- bugfix: 73_AutoShuttersControl: fix window close fn then Mode_Up off
- change: 93_DbLog: change SQL-Statement for SVG delta-h and delta-d plots,

View File

@ -434,7 +434,7 @@ sub ZoneMinder_GetFromJson {
my $poma = $`;
$searchLength = length($ma);
} else {
Log3 $name, 1, "ZoneMinder ($name) - $searchString NOT found. Please report, this is a problem.";
Log3 $name, 4, "ZoneMinder ($name) - $searchString NOT found in $config.";
return;
}
@ -457,7 +457,8 @@ sub ZoneMinder_API_UpdateMonitors_Callback {
foreach my $monitorData (@monitors) {
my $monitorId = ZoneMinder_GetConfigValueByKey($hash, $monitorData, 'Id');
next if ! defined $monitorId;
if ( $monitorId =~ /^[0-9]+$/ ) {
ZoneMinder_UpdateMonitorAttributes($hash, $monitorData, $monitorId);
} else {
@ -492,6 +493,7 @@ sub ZoneMinder_API_CreateMonitors_Callback {
foreach my $monitorData (@monitors) {
my $monitorId = ZoneMinder_GetConfigValueByKey($hash, $monitorData, 'Id');
next if ! defined $monitorId;
if ( $monitorId =~ /^[0-9]+$/ ) {
my $dispatchResult = Dispatch($hash, "createMonitor:$monitorId", undef);
}
@ -633,6 +635,9 @@ sub ZoneMinder_API_QueryEventDetails_Callback {
$data =~ s/\R//g;
my $zmMonitorId = ZoneMinder_GetConfigValueByKey($hash, $data, 'MonitorId');
if ( ! defined $zmMonitorId ) {
return undef;
}
my $zmEventId = ZoneMinder_GetConfigValueByKey($hash, $data, 'Id');
my $zmNotes = ZoneMinder_GetConfigValueByKey($hash, $data, 'Notes');