mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-04 22:19:38 +00:00
Chomp does not does what I want.
git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@1029 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
aaf08367d7
commit
681d170262
6
fhem.pl
6
fhem.pl
@ -167,7 +167,7 @@ my $nextat; # Time when next timer will be triggered.
|
|||||||
my $intAtCnt=0;
|
my $intAtCnt=0;
|
||||||
my %duplicate; # Pool of received msg for multi-fhz/cul setups
|
my %duplicate; # Pool of received msg for multi-fhz/cul setups
|
||||||
my $duplidx=0; # helper for the above pool
|
my $duplidx=0; # helper for the above pool
|
||||||
my $cvsid = '$Id: fhem.pl,v 1.152 2011-09-23 11:52:00 rudolfkoenig Exp $';
|
my $cvsid = '$Id: fhem.pl,v 1.153 2011-09-30 15:46:19 rudolfkoenig Exp $';
|
||||||
my $namedef =
|
my $namedef =
|
||||||
"where <name> is either:\n" .
|
"where <name> is either:\n" .
|
||||||
"- a single device name\n" .
|
"- a single device name\n" .
|
||||||
@ -2506,7 +2506,7 @@ ReplaceEventMap($$$)
|
|||||||
return $str if(!$em);
|
return $str if(!$em);
|
||||||
|
|
||||||
my $sc = " "; # Split character
|
my $sc = " "; # Split character
|
||||||
my $fc = substr($em, 0, 1); # First character of the eventmap
|
my $fc = substr($em, 0, 1); # First character of the eventMap
|
||||||
if($fc eq "," || $fc eq "/") {
|
if($fc eq "," || $fc eq "/") {
|
||||||
$sc = $fc;
|
$sc = $fc;
|
||||||
$em = substr($em, 1);
|
$em = substr($em, 1);
|
||||||
@ -2544,7 +2544,7 @@ setGlobalAttrBeforeFork()
|
|||||||
my $f = $attr{global}{configfile};
|
my $f = $attr{global}{configfile};
|
||||||
open(FH, $f) || die("Cant open $f: $!\n");
|
open(FH, $f) || die("Cant open $f: $!\n");
|
||||||
while(my $l = <FH>) {
|
while(my $l = <FH>) {
|
||||||
chomp($l);
|
$l =~ s/[\r\n]//g;
|
||||||
next if($l !~ m/^attr\s+global\s+([^\s]+)\s+(.*)$/);
|
next if($l !~ m/^attr\s+global\s+([^\s]+)\s+(.*)$/);
|
||||||
my ($n,$v) = ($1,$2);
|
my ($n,$v) = ($1,$2);
|
||||||
$v =~ s/#.*//;
|
$v =~ s/#.*//;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user