Changes to allow testing interface for new NaCl Proxy
BUG=none
TEST=ppapi/tests
Review URL: https://chromiumcodereview.appspot.com/10918083
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@157871 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/ppapi/proxy/ppb_audio_proxy.cc b/ppapi/proxy/ppb_audio_proxy.cc
index 2f91fc7..5a6b43ac 100644
--- a/ppapi/proxy/ppb_audio_proxy.cc
+++ b/ppapi/proxy/ppb_audio_proxy.cc
@@ -74,6 +74,13 @@
}
Audio::~Audio() {
+#if defined(OS_NACL)
+ // Invoke StopPlayback() to ensure audio back-end has a chance to send the
+ // escape value over the sync socket, which will terminate the client side
+ // audio callback loop. This is required for NaCl Plugins that can't escape
+ // by shutting down the sync_socket.
+ StopPlayback();
+#endif
PpapiGlobals::Get()->GetResourceTracker()->ReleaseResource(config_);
}