Camera: Avoid NPE when extension results are not supported
Bug: 240017175 Test: atest -c -d cts/tests/camera/src/android/hardware/camera2/cts/CameraExtensionSessionTest.java#testRepeatingAndCaptureCombined Change-Id: I0b82039a103ac2a55f71a6aea505d7c7c696d7be
This commit is contained in:
@@ -1693,8 +1693,10 @@ public final class CameraExtensionSessionImpl extends CameraExtensionSession {
|
||||
((i != idx) || notifyCurrentIndex)) {
|
||||
TotalCaptureResult result = previewMap.valueAt(i).second;
|
||||
Long timestamp = result.get(CaptureResult.SENSOR_TIMESTAMP);
|
||||
mCaptureResultHandler.onCaptureCompleted(timestamp,
|
||||
initializeFilteredResults(result));
|
||||
if (mCaptureResultHandler != null) {
|
||||
mCaptureResultHandler.onCaptureCompleted(timestamp,
|
||||
initializeFilteredResults(result));
|
||||
}
|
||||
|
||||
Log.w(TAG, "Preview frame drop with timestamp: " + previewMap.keyAt(i));
|
||||
final long ident = Binder.clearCallingIdentity();
|
||||
|
||||
Reference in New Issue
Block a user