diff options
author | sergeyu <sergeyu@chromium.org> | 2014-09-16 17:16:46 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-17 00:17:07 +0000 |
commit | efb18cbb572a9c798c6ef6c81a0a6cb54935814d (patch) | |
tree | ed45aeead68c855b7ac958b7c3e5cc4f2237cd4f /remoting | |
parent | b69fbca034e3c2181e0a12cf02baec4de526bf25 (diff) | |
download | chromium_src-efb18cbb572a9c798c6ef6c81a0a6cb54935814d.zip chromium_src-efb18cbb572a9c798c6ef6c81a0a6cb54935814d.tar.gz chromium_src-efb18cbb572a9c798c6ef6c81a0a6cb54935814d.tar.bz2 |
Fix V1 app crash when verifying sockets API is available.
the code that checks that sockets API is available was checking that
chrome.socket.secure is defined without verifying that chrome.socket
is defined. As result the app would not connect.
BUG=414366
Review URL: https://codereview.chromium.org/567293005
Cr-Commit-Position: refs/heads/master@{#295183}
Diffstat (limited to 'remoting')
-rw-r--r-- | remoting/webapp/session_connector.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/remoting/webapp/session_connector.js b/remoting/webapp/session_connector.js index 6d6e92b..04fe425 100644 --- a/remoting/webapp/session_connector.js +++ b/remoting/webapp/session_connector.js @@ -371,7 +371,7 @@ remoting.SessionConnector.prototype.connectSignaling_ = function() { // Only use XMPP when TCP API is available and TLS support is enabled. That's // not the case for V1 app (socket API is available only to platform apps) // and for Chrome releases before 38. - if (chrome.socket.secure) { + if (chrome.socket && chrome.socket.secure) { this.signalStrategy_ = /** @type {remoting.SignalStrategy} */ (new remoting.XmppConnection(this.onSignalingState_.bind(this))); } else { |