1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Fix tcp in node finishing packets when in streaming base64 receive mode.

This commit is contained in:
Dave Conway-Jones 2020-06-22 22:40:15 +01:00
parent 432ed264c2
commit b72ca439e2
No known key found for this signature in database
GPG Key ID: 302A6725C594817F

View File

@ -199,7 +199,7 @@ module.exports = function(RED) {
}
});
socket.on('end', function() {
if (!node.stream || (node.datatype === "utf8" && node.newline !== "")) {
if (!node.stream || (node.datatype === "utf8" && node.newline !== "") || (node.datatype === "base64")) {
if (buffer.length > 0) {
var msg = {topic:node.topic, payload:buffer, ip:fromi, port:fromp};
msg._session = {type:"tcp",id:id};