From e00d8752fde1ad20ca106401bae4621a1d6b31e2 Mon Sep 17 00:00:00 2001 From: nasseeder1 Date: Fri, 31 Jan 2020 21:55:56 +0000 Subject: [PATCH] 93_DbLog: fix warning, Forum: #107950 git-svn-id: https://svn.fhem.de/fhem/trunk@21087 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/CHANGED | 1 + fhem/FHEM/93_DbLog.pm | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/fhem/CHANGED b/fhem/CHANGED index 792155560..791fc1917 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -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: 93_DbLog: fix warning, Forum: #107950 - feature: 98_weekprofile: new command import_profile - bugfix: 98_weekprofile: html output for command get associations - bugfix: msgSchema: change Typo LGTV_WebOS diff --git a/fhem/FHEM/93_DbLog.pm b/fhem/FHEM/93_DbLog.pm index f0abff1b7..446175188 100644 --- a/fhem/FHEM/93_DbLog.pm +++ b/fhem/FHEM/93_DbLog.pm @@ -30,6 +30,7 @@ no if $] >= 5.017011, warnings => 'experimental::smartmatch'; # Version History intern by DS_Starter: our %DbLog_vNotesIntern = ( + "4.9.10" => "31.01.2020 fix warning, Forum: #107950 ", "4.9.9" => "21.01.2020 default ParseEvent changed again, Forum: #106769 ", "4.9.8" => "17.01.2020 adjust configCheck with plotEmbed check. Forum: #107383 ", "4.9.7" => "13.01.2020 change datetime pattern in valueFn of DbLog_addCacheLine. Forum: #107285 ", @@ -1556,7 +1557,7 @@ sub DbLog_Log($$) { # synchoner Mode return if($hash->{HELPER}{REOPEN_RUNS}); # return wenn "reopen" mit Ablaufzeit gestartet ist my $error = DbLog_Push($hash, $vb4show, @row_array); - Log3 ($name, 5, "DbLog $name -> DbLog_Push Returncode: $error") if($vb4show); + Log3 ($name, 5, "DbLog $name -> DbLog_Push Returncode: $error") if($error && $vb4show); CancelDelayedShutdown($name) if($hash->{HELPER}{SHUTDOWNSEQ}); Log3 ($name, 2, "DbLog $name - Last database write cycle done") if(delete $hash->{HELPER}{SHUTDOWNSEQ}); my $state = $error?$error:(IsDisabled($name))?"disabled":"connected"; @@ -1656,8 +1657,8 @@ sub DbLog_Push(@) { my $bi = AttrVal($name, "bulkInsert", 0); my $history = $hash->{HELPER}{TH}; my $current = $hash->{HELPER}{TC}; - my $errorh = 0; - my $error = 0; + my $errorh = ""; + my $error = ""; my $doins = 0; # Hilfsvariable, wenn "1" sollen inserts in Tabelle current erfolgen (updates schlugen fehl) my $dbh;