Socket Close presence is absent separate function
This commit is contained in:
parent
482f500c31
commit
e5411b00d8
@ -1403,9 +1403,7 @@ sub LGTV_WebOS_PresenceDone($) {
|
|||||||
|
|
||||||
readingsSingleUpdate($hash, 'presence', $response, 1);
|
readingsSingleUpdate($hash, 'presence', $response, 1);
|
||||||
|
|
||||||
LGTV_WebOS_Close($hash)
|
LGTV_WebOS_SocketClosePresenceAbsent($hash,$response);
|
||||||
if( $response eq 'absent' and not IsDisabled($name) and $hash->{CD} ); # https://forum.fhem.de/index.php/topic,66671.msg694578.html#msg694578
|
|
||||||
# Sobald pingPresence absent meldet und der Socket noch steht soll er geschlossen werden, da sonst FHEM nach 4-6 min für 10 min blockiert
|
|
||||||
|
|
||||||
Log3 $name, 4, "Sub LGTV_WebOS_PresenceDone ($name) - presence done";
|
Log3 $name, 4, "Sub LGTV_WebOS_PresenceDone ($name) - presence done";
|
||||||
}
|
}
|
||||||
@ -1422,6 +1420,18 @@ sub LGTV_WebOS_PresenceAborted($) {
|
|||||||
Log3 $name, 4, "Sub LGTV_WebOS_PresenceAborted ($name) - The BlockingCall Process terminated unexpectedly. Timedout!";
|
Log3 $name, 4, "Sub LGTV_WebOS_PresenceAborted ($name) - The BlockingCall Process terminated unexpectedly. Timedout!";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sub LGTV_WebOS_SocketClosePresenceAbsent($$) {
|
||||||
|
|
||||||
|
my ($hash,$presence) = @_;
|
||||||
|
|
||||||
|
my $name = $hash->{NAME};
|
||||||
|
|
||||||
|
|
||||||
|
LGTV_WebOS_Close($hash)
|
||||||
|
if( $presence eq 'absent' and not IsDisabled($name) and $hash->{CD} ); # https://forum.fhem.de/index.php/topic,66671.msg694578.html#msg694578
|
||||||
|
# Sobald pingPresence absent meldet und der Socket noch steht soll er geschlossen werden, da sonst FHEM nach 4-6 min für 10 min blockiert
|
||||||
|
}
|
||||||
|
|
||||||
sub LGTV_WebOS_WakeUp_Udp($@) {
|
sub LGTV_WebOS_WakeUp_Udp($@) {
|
||||||
|
|
||||||
my ($hash,$mac_addr,$host,$port) = @_;
|
my ($hash,$mac_addr,$host,$port) = @_;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user