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

Commit 346a2e69 authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 9428515 from 143627b2 to tm-qpr2-release

Change-Id: I9a61514c6fc66595db3ff3c931a5c5295c50c976
parents 685339b1 143627b2
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -64,6 +64,11 @@ std::shared_ptr<C2SurfaceSyncMemory> C2SurfaceSyncMemory::Import(
    }

    HandleSyncMem *o = static_cast<HandleSyncMem*>(handle);
    if (o->size() < sizeof(C2SyncVariables)) {
        android_errorWriteLog(0x534e4554, "240140929");
        return nullptr;
    }

    void *ptr = mmap(NULL, o->size(), PROT_READ | PROT_WRITE, MAP_SHARED, o->memFd(), 0);

    if (ptr == MAP_FAILED) {