From 421dfd5842d44a77883fac7ad2781c363e77aed3 Mon Sep 17 00:00:00 2001 From: Pablo Gamito Date: Tue, 22 Sep 2020 18:11:45 +0000 Subject: Convert SurfaceControl parceling to SAFE_PARCEL Test: Existing tests Change-Id: I7618f9677e538fca90ae5cfb0693e5926701f564 --- libs/gui/SurfaceComposerClient.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'libs/gui/SurfaceComposerClient.cpp') diff --git a/libs/gui/SurfaceComposerClient.cpp b/libs/gui/SurfaceComposerClient.cpp index 3fda059497..0264e17b97 100644 --- a/libs/gui/SurfaceComposerClient.cpp +++ b/libs/gui/SurfaceComposerClient.cpp @@ -431,7 +431,7 @@ status_t SurfaceComposerClient::Transaction::readFromParcel(const Parcel* parcel } for (size_t j = 0; j < numSurfaces; j++) { sp surface; - surface = SurfaceControl::readFromParcel(parcel); + SAFE_PARCEL(SurfaceControl::readFromParcel, *parcel, &surface); listenerCallbacks[listener].surfaceControls.insert(surface); } } @@ -507,7 +507,7 @@ status_t SurfaceComposerClient::Transaction::writeToParcel(Parcel* parcel) const } parcel->writeUint32(static_cast(callbackInfo.surfaceControls.size())); for (auto surfaceControl : callbackInfo.surfaceControls) { - surfaceControl->writeToParcel(parcel); + SAFE_PARCEL(surfaceControl->writeToParcel, *parcel); } } -- cgit v1.2.3-59-g8ed1b