mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-05-04 22:19:38 +00:00
Avoiding recursive watchdog entries
git-svn-id: https://svn.fhem.de/fhem/trunk@268 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
b7d3b1d525
commit
e32f7a428c
@ -59,6 +59,7 @@ watchdog_Notify($$)
|
|||||||
|
|
||||||
my $ln = $ntfy->{NAME};
|
my $ln = $ntfy->{NAME};
|
||||||
return "" if($attr{$ln} && $attr{$ln}{disable});
|
return "" if($attr{$ln} && $attr{$ln}{disable});
|
||||||
|
return "" if($ntfy->{INWATCHDOG});
|
||||||
|
|
||||||
my $n = $dev->{NAME};
|
my $n = $dev->{NAME};
|
||||||
my $re1 = $ntfy->{RE1};
|
my $re1 = $ntfy->{RE1};
|
||||||
@ -91,8 +92,10 @@ watchdog_Trigger($)
|
|||||||
my ($ntfy) = @_;
|
my ($ntfy) = @_;
|
||||||
Log(3, "Watchdog $ntfy->{NAME} triggered");
|
Log(3, "Watchdog $ntfy->{NAME} triggered");
|
||||||
my $exec = SemicolonEscape($ntfy->{CMD});;
|
my $exec = SemicolonEscape($ntfy->{CMD});;
|
||||||
AnalyzeCommandChain(undef, $exec);
|
|
||||||
$ntfy->{STATE} = "triggered";
|
$ntfy->{STATE} = "triggered";
|
||||||
|
$ntfy->{INWATCHDOG} = 1;
|
||||||
|
AnalyzeCommandChain(undef, $exec);
|
||||||
|
$ntfy->{INWATCHDOG} = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
sub
|
sub
|
||||||
|
Loading…
x
Reference in New Issue
Block a user