mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-02 06:55:26 +00:00
CUL_HM: fix bug regSet from last update
git-svn-id: https://svn.fhem.de/fhem/trunk@23075 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
d783ec05c7
commit
e325e606e4
@ -4593,7 +4593,7 @@ sub CUL_HM_Set($@) {#+++++++++++++++++ set command+++++++++++++++++++++++++++++
|
||||
if($param =~ m/^\((.*)\)$/ ){ # list of options?
|
||||
my @parLst = split('\|',$1);
|
||||
if( defined $parIn[$pCnt]){ # user param provided
|
||||
my ($tmp1) = map{my$foo=$_;;$foo =~ s/(.)/\\$1/g;;$foo}($parIn[$pCnt]);
|
||||
my ($tmp1) = map{my$foo=$_;$foo =~ s/([\?\*\+])/\\$1/g;$foo}($parIn[$pCnt]);
|
||||
if( $parIn[$pCnt] !~ m/[:\{\[\(]/ && grep/$tmp1/,@parLst){ # parameter not comparable or matched
|
||||
}
|
||||
elsif($param =~ m/([\-\d\.]*)\.\.([\-\d\.]*)/ ){# we check for min/max but not for step
|
||||
@ -5100,7 +5100,7 @@ sub CUL_HM_Set($@) {#+++++++++++++++++ set command+++++++++++++++++++++++++++++
|
||||
my $mdAl = CUL_HM_getAliasModel($hash);
|
||||
my @regArr = CUL_HM_getRegN($st,$mdAl,($roleD?"00":""),($roleC?$chn:""));
|
||||
|
||||
my ($tmp1) = map{my$foo=$_;;$foo =~ s/(.)/\\$1/g;;$foo}($regName); # we need to consider spacial chars
|
||||
my ($tmp1) = map{my$foo=$_;$foo =~ s/([\+\?\*])/\\$1/g;$foo}($regName); # we need to consider spacial chars
|
||||
return "$regName failed: supported register are ".join(" ",sort @regArr)
|
||||
if (!grep /^$tmp1$/,@regArr );
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user