summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorwtc@google.com <wtc@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-17 16:06:06 +0000
committerwtc@google.com <wtc@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2010-12-17 16:06:06 +0000
commit8a9b4596ed3fd75411fb4a26c8e2c2f0a63a0d0a (patch)
tree28b7d79c28809661f8d8b38a082ad019e6fd39b7 /chrome
parent8855583c5785c972d557a800684da81a1dcb6646 (diff)
downloadchromium_src-8a9b4596ed3fd75411fb4a26c8e2c2f0a63a0d0a.zip
chromium_src-8a9b4596ed3fd75411fb4a26c8e2c2f0a63a0d0a.tar.gz
chromium_src-8a9b4596ed3fd75411fb4a26c8e2c2f0a63a0d0a.tar.bz2
The MediatorThread worker thread needs to have a CertVerifier
for the SSLClientSocket objects it creates. R=agl,akalin BUG=63357,67239 TEST=Sync should not crash. Review URL: http://codereview.chromium.org/5958001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@69549 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/sync/tools/sync_listen_notifications.cc11
1 files changed, 8 insertions, 3 deletions
diff --git a/chrome/browser/sync/tools/sync_listen_notifications.cc b/chrome/browser/sync/tools/sync_listen_notifications.cc
index 0b20db1..d15ded3 100644
--- a/chrome/browser/sync/tools/sync_listen_notifications.cc
+++ b/chrome/browser/sync/tools/sync_listen_notifications.cc
@@ -25,6 +25,7 @@
#include "jingle/notifier/listener/send_update_task.h"
#include "jingle/notifier/listener/subscribe_task.h"
#include "jingle/notifier/listener/xml_element_util.h"
+#include "net/base/cert_verifier.h"
#include "net/base/ssl_config_service.h"
#include "net/socket/client_socket_factory.h"
#include "talk/base/cryptstring.h"
@@ -66,10 +67,12 @@ class XmppNotificationClient : public notifier::XmppConnection::Delegate {
virtual ~XmppNotificationClient() {}
// Connect with the given XMPP settings and run until disconnected.
- void Run(const buzz::XmppClientSettings& xmpp_client_settings) {
+ void Run(const buzz::XmppClientSettings& xmpp_client_settings,
+ net::CertVerifier* cert_verifier) {
DCHECK(!xmpp_connection_.get());
xmpp_connection_.reset(
- new notifier::XmppConnection(xmpp_client_settings, this, NULL));
+ new notifier::XmppConnection(xmpp_client_settings, cert_verifier,
+ this, NULL));
MessageLoop::current()->Run();
DCHECK(!xmpp_connection_.get());
}
@@ -295,6 +298,8 @@ int main(int argc, char* argv[]) {
}
xmpp_client_settings.set_server(addr);
+ net::CertVerifier cert_verifier;
+
MessageLoopForIO message_loop;
// Connect and listen.
@@ -310,7 +315,7 @@ int main(int argc, char* argv[]) {
}
XmppNotificationClient xmpp_notification_client(
observers.begin(), observers.end());
- xmpp_notification_client.Run(xmpp_client_settings);
+ xmpp_notification_client.Run(xmpp_client_settings, &cert_verifier);
return 0;
}