mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-10 03:06:37 +00:00
24_TPLinkHS110: Reverted to state before retry on connect
git-svn-id: https://svn.fhem.de/fhem/trunk@14381 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
4981ca754b
commit
1479b3d294
@ -99,12 +99,7 @@ sub TPLinkHS110_Get($$)
|
||||
Type => SOCK_STREAM,
|
||||
Timeout => $hash->{TIMEOUT} )
|
||||
or return "Couldn't connect to $remote_host:$remote_port: $@\n";
|
||||
eval {
|
||||
$socket->send($c);
|
||||
} or do {
|
||||
Log3 $hash, 2, "TPLinkHS110: $name error sending. Retrying one more time.";
|
||||
$socket->send($c);
|
||||
};
|
||||
$socket->send($c);
|
||||
my $data;
|
||||
my $retval = $socket->recv($data,8192);
|
||||
$socket->close();
|
||||
@ -139,12 +134,7 @@ sub TPLinkHS110_Get($$)
|
||||
Type => SOCK_STREAM,
|
||||
Timeout => $hash->{TIMEOUT} )
|
||||
or return "Couldn't connect to $remote_host:$remote_port: $@\n";
|
||||
eval {
|
||||
$socket->send($c);
|
||||
} or do {
|
||||
Log3 $hash, 2, "TPLinkHS110: $name error sending. Retrying one more time.";
|
||||
$socket->send($c);
|
||||
};
|
||||
$socket->send($rc);
|
||||
my $rdata;
|
||||
$retval = $socket->recv($rdata,8192);
|
||||
$socket->close();
|
||||
@ -174,12 +164,7 @@ sub TPLinkHS110_Get($$)
|
||||
Type => SOCK_STREAM,
|
||||
Timeout => $hash->{TIMEOUT} )
|
||||
or return "Couldn't connect to $remote_host:$remote_port: $@\n";
|
||||
eval {
|
||||
$socket->send($c);
|
||||
} or do {
|
||||
Log3 $hash, 2, "TPLinkHS110: $name error sending. Retrying one more time.";
|
||||
$socket->send($c);
|
||||
};
|
||||
$socket->send($c);
|
||||
my $data;
|
||||
$retval = $socket->recv($data,8192);
|
||||
$socket->close();
|
||||
@ -236,12 +221,7 @@ sub TPLinkHS110_Set($$)
|
||||
Type => SOCK_STREAM,
|
||||
Timeout => $hash->{TIMEOUT})
|
||||
or return "Couldn't connect to $remote_host:$remote_port: $@\n";
|
||||
eval {
|
||||
$socket->send($c);
|
||||
} or do {
|
||||
Log3 $hash, 2, "TPLinkHS110: $name error sending. Retrying one more time.";
|
||||
$socket->send($c);
|
||||
};
|
||||
$socket->send($c);
|
||||
my $data;
|
||||
my $retval = $socket->recv($data,8192);
|
||||
$socket->close();
|
||||
@ -330,12 +310,7 @@ sub TPLinkHS110_Attr {
|
||||
Type => SOCK_STREAM,
|
||||
Timeout => $hash->{TIMEOUT} )
|
||||
or return "Couldn't connect to $remote_host:$remote_port: $@\n";
|
||||
eval {
|
||||
$socket->send($c);
|
||||
} or do {
|
||||
Log3 $hash, 2, "TPLinkHS110: $name error sending. Retrying one more time.";
|
||||
$socket->send($c);
|
||||
};
|
||||
$socket->send($c);
|
||||
my $data;
|
||||
my $retval = $socket->recv($data,8192);
|
||||
$socket->close();
|
||||
|
Loading…
x
Reference in New Issue
Block a user