From 716f77eb8542b589d52e30d8c445df4fa3c7beaa Mon Sep 17 00:00:00 2001 From: Wesley Miaw Date: Fri, 9 Sep 2016 16:12:26 -0700 Subject: [PATCH] Make sure to provide a timeout and callback to Url's ByteArrayInputStream and MslControl.receive()'s MessageInputStream. --- core/src/main/javascript/io/Url.js | 5 +++-- core/src/main/javascript/msg/MslControl.js | 6 +++++- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/core/src/main/javascript/io/Url.js b/core/src/main/javascript/io/Url.js index 2fde2a29..c9220d4f 100644 --- a/core/src/main/javascript/io/Url.js +++ b/core/src/main/javascript/io/Url.js @@ -214,8 +214,9 @@ var IHttpLocation = util.Class.create({ close: function close(timeout, callback) { InterruptibleExecutor(callback, function() { if (this._buffer) - this._buffer.close(); - return true; + this._buffer.close(timeout, callback); + else + return true; }, this); }, diff --git a/core/src/main/javascript/msg/MslControl.js b/core/src/main/javascript/msg/MslControl.js index 53b18ec6..f37a513d 100644 --- a/core/src/main/javascript/msg/MslControl.js +++ b/core/src/main/javascript/msg/MslControl.js @@ -2944,7 +2944,11 @@ var MslControl$MslChannel; function handshakeResponse(request) { InterruptibleExecutor(callback, function() { // Close the request. We're done with it. - request.close(); + request.close(this._timeout, { + result: function() {}, + timeout: function() {}, + error: function() {} + }); // This is a handshake request so automatically return a response. //