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

DevIo.pm: no strict refs for initFn (Forum #110125)

git-svn-id: https://svn.fhem.de/fhem/trunk@21665 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
rudolfkoenig 2020-04-13 21:10:42 +00:00
parent e35cc148ed
commit 6a5aaa0be1

View File

@ -247,7 +247,9 @@ DevIo_OpenDev($$$;$)
my $ret;
if($initfn) {
my $hadFD = defined($hash->{FD});
no strict "refs";
$ret = &$initfn($hash);
use strict "refs";
if($ret) {
if($hadFD && !defined($hash->{FD})) { # Forum #54732 / ser2net
DevIo_Disconnected($hash);