Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 09cf0e5c authored by Chih-yu Huang's avatar Chih-yu Huang Committed by Android (Google) Code Review
Browse files

Merge "Close the handle returned by WrapNativeCodec2GrallocHandle()" into sc-dev

parents 134b9358 ef546db3
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -2260,6 +2260,8 @@ static void android_media_MediaCodec_native_queueHardwareBuffer(
    c2_status_t c2err = sGrallocAlloc->priorGraphicAllocation(handle, &alloc);
    if (c2err != C2_OK) {
        ALOGW("Failed to wrap AHardwareBuffer into C2GraphicAllocation");
        native_handle_close(handle);
        native_handle_delete(handle);
        throwExceptionAsNecessary(env, BAD_VALUE);
        return;
    }