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

Commit 246ae501 authored by Mathias Agopian's avatar Mathias Agopian Committed by Android (Google) Code Review
Browse files

Merge "Read leftover parcel data when a parceled Surface is found in the cache."

parents 875dee4e 3f945fa5
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -277,6 +277,11 @@ sp<Surface> Surface::readFromParcel(const Parcel& data) {
    if (surface == 0) {
       surface = new Surface(data, binder);
       sCachedSurfaces.add(binder, surface);
    } else {
        // The Surface was found in the cache, but we still should clear any
        // remaining data from the parcel.
        data.readStrongBinder();  // ISurfaceTexture
        data.readInt32();         // identity
    }
    if (surface->mSurface == NULL && surface->getISurfaceTexture() == NULL) {
        surface = 0;