blob: 0a6bee378bff28bcf564a9ed3cca6fb137dee5df (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
Copied from https://hg.mozilla.org/releases/mozilla-esr38/raw-rev/e7c23c08bf84
# HG changeset patch
# User Randell Jesup <rjesup@jesup.org>
# Date 1458543433 14400
# Node ID e7c23c08bf84a02d9154f31e0c5d121a45884a69
# Parent a6de1f453712edabff597879398606708c191098
Bug 1254876: assert windows recording is shut down r=pkerr a=ritu
MozReview-Commit-ID: JRqxBb5TgrE
diff --git a/media/webrtc/trunk/webrtc/modules/audio_device/win/audio_device_core_win.cc b/media/webrtc/trunk/webrtc/modules/audio_device/win/audio_device_core_win.cc
--- a/media/webrtc/trunk/webrtc/modules/audio_device/win/audio_device_core_win.cc
+++ b/media/webrtc/trunk/webrtc/modules/audio_device/win/audio_device_core_win.cc
@@ -567,16 +567,19 @@ AudioDeviceWindowsCore::AudioDeviceWindo
// ----------------------------------------------------------------------------
AudioDeviceWindowsCore::~AudioDeviceWindowsCore()
{
WEBRTC_TRACE(kTraceMemory, kTraceAudioDevice, _id, "%s destroyed", __FUNCTION__);
Terminate();
+ // Recording thread should be shut down before this!
+ assert(_hRecThread == NULL);
+
// The IMMDeviceEnumerator is created during construction. Must release
// it here and not in Terminate() since we don't recreate it in Init().
SAFE_RELEASE(_ptrEnumerator);
_ptrAudioBuffer = NULL;
if (NULL != _hRenderSamplesReadyEvent)
{
|