From b171f87206e04ebcb719038852b683ed7419bdc1 Mon Sep 17 00:00:00 2001 From: rudolfkoenig <> Date: Mon, 2 Sep 2019 07:00:48 +0000 Subject: [PATCH] 10_ZWAVE.pm: small Firmware patch (Forum #101961) git-svn-id: https://svn.fhem.de/fhem/trunk@20091 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/FHEM/10_ZWave.pm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/fhem/FHEM/10_ZWave.pm b/fhem/FHEM/10_ZWave.pm index 4b2634bb8..f0e45fdf6 100644 --- a/fhem/FHEM/10_ZWave.pm +++ b/fhem/FHEM/10_ZWave.pm @@ -5452,9 +5452,10 @@ ZWave_firmware($$) return("Firmware update with FIRMWARE_UPDATE_MD classversion > 4 ". "not supported", "EMPTY") if($classVersion > 4); my ($target, $fwFile) = split / /, $args; - my $usage = "wrong argumets, need: "; - return ($usage, "EMPTY") if (!$target || !$fwFile); - + my $usage = "wrong argumets, need: "; + return ($usage, "EMPTY") + if(!defined($target) || $target !~ m/^\d+$/ || !$fwFile); + my $fName = "$attr{global}{modpath}/FHEM/firmware/$fwFile"; my $l = -s $fName; return "$fName does not exists, or is empty" if(!$l);