diff options
author | nfullagar@google.com <nfullagar@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-21 03:30:19 +0000 |
---|---|---|
committer | nfullagar@google.com <nfullagar@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-21 03:30:19 +0000 |
commit | f4452670c8ca44c6c478997167e030b49500ed83 (patch) | |
tree | d167649e86781b27d12bbf7b8f23e401ddcf265c /ppapi | |
parent | 02aff8a2e732a0450b02fb7fbf951d6815f3d9c2 (diff) | |
download | chromium_src-f4452670c8ca44c6c478997167e030b49500ed83.zip chromium_src-f4452670c8ca44c6c478997167e030b49500ed83.tar.gz chromium_src-f4452670c8ca44c6c478997167e030b49500ed83.tar.bz2 |
Only close the sync socket if it is non-NULL. This fixes
a NaCl page reload / surf-away regression.
BUG=NaCl ppapi audio proxy
TEST=native_client/tests/ppapi_example_audio
Review URL: http://codereview.chromium.org/6300011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@72099 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi')
-rw-r--r-- | ppapi/shared_impl/audio_impl.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ppapi/shared_impl/audio_impl.cc b/ppapi/shared_impl/audio_impl.cc index 83b73f6..30e1bab 100644 --- a/ppapi/shared_impl/audio_impl.cc +++ b/ppapi/shared_impl/audio_impl.cc @@ -18,7 +18,8 @@ AudioImpl::AudioImpl() AudioImpl::~AudioImpl() { // Closing the socket causes the thread to exit - wait for it. - socket_->Close(); + if (socket_.get()) + socket_->Close(); if (audio_thread_.get()) { audio_thread_->Join(); audio_thread_.reset(); |