mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-03-03 16:56:54 +00:00
HttpUtils.pm: fix data for unicodeEncoding (Forum #131207)
git-svn-id: https://svn.fhem.de/fhem/trunk@26916 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
7157826e22
commit
68939bea21
@ -736,7 +736,10 @@ HttpUtils_Connect2($)
|
||||
}
|
||||
};
|
||||
|
||||
$data = $hdr.(defined($data) ? $data:"");
|
||||
$data = "" if(!defined($data));
|
||||
$data = Encode::decode("UTF-8", $data) if($unicodeEncoding);
|
||||
$data = $hdr.$data;
|
||||
|
||||
$hash->{directWriteFn} = sub($) { # Nonblocking write
|
||||
my $ret = syswrite $hash->{conn}, $data;
|
||||
if(!defined($ret) || $ret <= 0) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user