2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-04-22 08:11:44 +00:00

MAX: fix conversion of addresses to lower case

git-svn-id: https://svn.fhem.de/fhem/trunk@3352 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
mgehre 2013-06-28 17:50:11 +00:00
parent f061497520
commit 78716ad076

View File

@ -172,12 +172,13 @@ CUL_MAX_Set($@)
} elsif($setting ~~ ["fakeSC", "fakeWT"]) { } elsif($setting ~~ ["fakeSC", "fakeWT"]) {
return "Invalid number of arguments" if(@args == 0); return "Invalid number of arguments" if(@args == 0);
my $dest = lc($args[0]); my $dest = $args[0];
#$dest may be either a name or an address #$dest may be either a name or an address
if(exists($defs{$dest})) { if(exists($defs{$dest})) {
return "Destination is not a MAX device" if($defs{$dest}{TYPE} ne "MAX"); return "Destination is not a MAX device" if($defs{$dest}{TYPE} ne "MAX");
$dest = $defs{$dest}{addr}; $dest = $defs{$dest}{addr};
} else { } else {
$dest = lc($dest); #address to lower-case
return "No MAX device with address $dest" if(!exists($modules{MAX}{defptr}{$dest})); return "No MAX device with address $dest" if(!exists($modules{MAX}{defptr}{$dest}));
} }