Fixed a race condition where some recording frames may not be released

bug - 3258924

Change-Id: I4f30d04a713676f5da40e6a7dd861510cc041f9b
This commit is contained in:
James Dong
2010-12-06 15:02:28 -08:00
parent c1576ad627
commit d57fbe887f

View File

@@ -359,6 +359,9 @@ void Camera::dataCallbackTimestamp(nsecs_t timestamp, int32_t msgType, const sp<
}
if (listener != NULL) {
listener->postDataTimestamp(timestamp, msgType, dataPtr);
} else {
LOGW("No listener was set. Drop a recording frame.");
releaseRecordingFrame(dataPtr);
}
}