Add some extra debugging for tracking down stop recording problem
bug - 2484098
diff --git a/android/author/android_audio_input.cpp b/android/author/android_audio_input.cpp
index 5e030f0..d50bf1c 100644
--- a/android/author/android_audio_input.cpp
+++ b/android/author/android_audio_input.cpp
@@ -948,7 +948,7 @@
////////////////////////////////////////////////////////////////////////////
PVMFStatus AndroidAudioInput::DoReset()
{
- LOGV("DoReset");
+ LOGD("DoReset: E");
// Remove and destroy the clock state observer
RemoveDestroyClockStateObs();
iExitAudioThread = true;
@@ -956,9 +956,9 @@
iFirstFrameReceived = false;
iFirstFrameTs = 0;
if(iAudioThreadStarted ){
- iAudioThreadSem->Signal();
- iAudioThreadTermSem->Wait();
- iAudioThreadStarted = false;
+ iAudioThreadSem->Signal();
+ iAudioThreadTermSem->Wait();
+ iAudioThreadStarted = false;
}
while(!iCmdQueue.empty())
{
@@ -979,6 +979,7 @@
iWriteResponseQueue.erase(&iWriteResponseQueue[0]);
}
iState = STATE_IDLE;
+ LOGD("DoReset: X");
return PVMFSuccess;
}
@@ -996,7 +997,7 @@
////////////////////////////////////////////////////////////////////////////
PVMFStatus AndroidAudioInput::DoStop()
{
- LOGV("DoStop");
+ LOGD("DoStop: E");
// Remove and destroy the clock state observer
RemoveDestroyClockStateObs();
@@ -1007,10 +1008,11 @@
iFirstFrameTs = 0;
iState = STATE_STOPPED;
if(iAudioThreadStarted ){
- iAudioThreadSem->Signal();
- iAudioThreadTermSem->Wait();
- iAudioThreadStarted = false;
+ iAudioThreadSem->Signal();
+ iAudioThreadTermSem->Wait();
+ iAudioThreadStarted = false;
}
+ LOGD("DoStop: X");
return PVMFSuccess;
}
diff --git a/android/author/android_camera_input.cpp b/android/author/android_camera_input.cpp
index 7f2c37c..71ce81c 100644
--- a/android/author/android_camera_input.cpp
+++ b/android/author/android_camera_input.cpp
@@ -991,7 +991,7 @@
// Does this work for reset?
PVMFStatus AndroidCameraInput::DoReset()
{
- LOGV("DoReset");
+ LOGD("DoReset: E");
// Remove and destroy the clock state observer
RemoveDestroyClockObs();
iDataEventCounter = 0;
@@ -1011,6 +1011,7 @@
}
Cancel();
iState = STATE_IDLE;
+ LOGD("DoReset: X");
return PVMFSuccess;
}
@@ -1027,7 +1028,7 @@
PVMFStatus AndroidCameraInput::DoStop(const AndroidCameraInputCmd& aCmd)
{
- LOGV("DoStop");
+ LOGD("DoStop: E");
// Remove and destroy the clock state observer
RemoveDestroyClockObs();
@@ -1040,6 +1041,7 @@
ReleaseQueuedFrames();
}
iState = STATE_STOPPED;
+ LOGD("DoStop: X");
return PVMFSuccess;
}