2
0
mirror of https://github.com/fhem/fhem-mirror.git synced 2025-01-31 12:49:34 +00:00

98_telnet.pm: avoid crash if async output channel is closed

git-svn-id: https://svn.fhem.de/fhem/trunk@23035 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig 2020-10-26 20:31:42 +00:00
parent f9dbaf6455
commit 53dbe57e9c

View File

@ -292,7 +292,7 @@ telnet_Output($$$)
{
my ($hash,$ret,$nonl) = @_;
if($ret) {
if($ret && defined($hash->{CD})) {
$ret = utf8ToLatin1($ret) if( $hash->{encoding} eq "latin1" );
if(!$nonl) { # AsyncOutput stuff
$ret = "\n$ret\n$hash->{prompt} " if( $hash->{showPrompt});