summaryrefslogtreecommitdiffstats
path: root/media/audio/win
diff options
context:
space:
mode:
authortommi@chromium.org <tommi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-08 22:34:03 +0000
committertommi@chromium.org <tommi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-12-08 22:34:03 +0000
commitf3a4a98ad887739616e06b9948a2deecc289b131 (patch)
tree8ffc8d88aec96449ba6b8fc11ccf1c7435e8f45c /media/audio/win
parent4d52923375a83af70372df26404e3dd80c2ef4b6 (diff)
downloadchromium_src-f3a4a98ad887739616e06b9948a2deecc289b131.zip
chromium_src-f3a4a98ad887739616e06b9948a2deecc289b131.tar.gz
chromium_src-f3a4a98ad887739616e06b9948a2deecc289b131.tar.bz2
Make check for 'opened' consistent across all audio stream implementations of Start() and log an error if open hasn't been called successfully.
This fixes BUG=106712 TEST=Run media_unittests. Review URL: http://codereview.chromium.org/8872028 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@113679 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/audio/win')
-rw-r--r--media/audio/win/audio_low_latency_input_win.cc3
-rw-r--r--media/audio/win/audio_low_latency_output_win.cc3
2 files changed, 2 insertions, 4 deletions
diff --git a/media/audio/win/audio_low_latency_input_win.cc b/media/audio/win/audio_low_latency_input_win.cc
index fc6630b..c6bb0ed 100644
--- a/media/audio/win/audio_low_latency_input_win.cc
+++ b/media/audio/win/audio_low_latency_input_win.cc
@@ -121,8 +121,7 @@ bool WASAPIAudioInputStream::Open() {
void WASAPIAudioInputStream::Start(AudioInputCallback* callback) {
DCHECK(callback);
- DCHECK(opened_);
-
+ DLOG_IF(ERROR, !opened_) << "Open() has not been called successfully";
if (!opened_)
return;
diff --git a/media/audio/win/audio_low_latency_output_win.cc b/media/audio/win/audio_low_latency_output_win.cc
index dc9c6ec..b036b94 100644
--- a/media/audio/win/audio_low_latency_output_win.cc
+++ b/media/audio/win/audio_low_latency_output_win.cc
@@ -117,8 +117,7 @@ bool WASAPIAudioOutputStream::Open() {
void WASAPIAudioOutputStream::Start(AudioSourceCallback* callback) {
DCHECK_EQ(GetCurrentThreadId(), creating_thread_id_);
DCHECK(callback);
- DCHECK(opened_);
-
+ DLOG_IF(ERROR, !opened_) << "Open() has not been called successfully";
if (!opened_)
return;