Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(174)

Unified Diff: media/audio/audio_manager.cc

Issue 6878081: Blind fix for a Linux only crash in AudioManager::Destroy (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/audio/audio_manager.cc
===================================================================
--- media/audio/audio_manager.cc (revision 82340)
+++ media/audio/audio_manager.cc (working copy)
@@ -14,11 +14,13 @@
void AudioManager::Destroy(void* not_used) {
g_destroy_called = true;
- g_audio_manager->Cleanup();
+ if (g_audio_manager) {
+ g_audio_manager->Cleanup();
- AudioManager* audio_manager = g_audio_manager;
- g_audio_manager = NULL;
- delete audio_manager;
+ AudioManager* audio_manager = g_audio_manager;
+ g_audio_manager = NULL;
+ delete audio_manager;
+ }
}
// static
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698