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

Side by Side Diff: content/browser/media/webrtc_internals.cc

Issue 310463002: Fix the aec dump crash when users disable aec dump without closing the "Save File" overlay. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixed the bots Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | content/renderer/media/webrtc/peer_connection_dependency_factory.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/media/webrtc_internals.h" 5 #include "content/browser/media/webrtc_internals.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "content/browser/media/webrtc_internals_ui_observer.h" 9 #include "content/browser/media/webrtc_internals_ui_observer.h"
10 #include "content/browser/web_contents/web_contents_view.h" 10 #include "content/browser/web_contents/web_contents_view.h"
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 FILE_PATH_LITERAL(""), 239 FILE_PATH_LITERAL(""),
240 web_contents->GetTopLevelNativeWindow(), 240 web_contents->GetTopLevelNativeWindow(),
241 NULL); 241 NULL);
242 #endif 242 #endif
243 #endif 243 #endif
244 } 244 }
245 245
246 void WebRTCInternals::DisableAecDump() { 246 void WebRTCInternals::DisableAecDump() {
247 #if defined(ENABLE_WEBRTC) 247 #if defined(ENABLE_WEBRTC)
248 aec_dump_enabled_ = false; 248 aec_dump_enabled_ = false;
249
250 // Tear down the dialog since the user has unchecked the AEC dump box.
251 select_file_dialog_ = NULL;
252
249 for (RenderProcessHost::iterator i( 253 for (RenderProcessHost::iterator i(
250 content::RenderProcessHost::AllHostsIterator()); 254 content::RenderProcessHost::AllHostsIterator());
251 !i.IsAtEnd(); i.Advance()) { 255 !i.IsAtEnd(); i.Advance()) {
252 i.GetCurrentValue()->DisableAecDump(); 256 i.GetCurrentValue()->DisableAecDump();
253 } 257 }
254 #endif 258 #endif
255 } 259 }
256 260
257 void WebRTCInternals::ResetForTesting() { 261 void WebRTCInternals::ResetForTesting() {
258 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 262 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
346 aec_dump_enabled_ = true; 350 aec_dump_enabled_ = true;
347 for (RenderProcessHost::iterator i( 351 for (RenderProcessHost::iterator i(
348 content::RenderProcessHost::AllHostsIterator()); 352 content::RenderProcessHost::AllHostsIterator());
349 !i.IsAtEnd(); i.Advance()) { 353 !i.IsAtEnd(); i.Advance()) {
350 i.GetCurrentValue()->EnableAecDump(aec_dump_file_path_); 354 i.GetCurrentValue()->EnableAecDump(aec_dump_file_path_);
351 } 355 }
352 } 356 }
353 #endif 357 #endif
354 358
355 } // namespace content 359 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/renderer/media/webrtc/peer_connection_dependency_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698