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

Commit b33a8aa5 authored by David Fu's avatar David Fu Committed by Android (Google) Code Review
Browse files

Merge "surfaceflinger_displayhardware_fuzzer: Bug Fix"

parents d5107dd3 c0935e2c
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -116,7 +116,8 @@ static constexpr hal::HWConfigId kActiveConfig = 0;
class DisplayHardwareFuzzer {
public:
    DisplayHardwareFuzzer(const uint8_t* data, size_t size) : mFdp(data, size) {
        mPhysicalDisplayId = SurfaceComposerClient::getInternalDisplayId().value();
        mPhysicalDisplayId = SurfaceComposerClient::getInternalDisplayId().value_or(
                PhysicalDisplayId::fromPort(mFdp.ConsumeIntegral<uint8_t>()));
    };
    void process();

+3 −1
Original line number Diff line number Diff line
@@ -529,7 +529,9 @@ public:
        ui::PixelFormat pixelFormat{};
        mFlinger->getHwComposer().allocateVirtualDisplay(halVirtualDisplayId, uiSize, &pixelFormat);

        PhysicalDisplayId physicalDisplayId = SurfaceComposerClient::getInternalDisplayId().value();
        PhysicalDisplayId physicalDisplayId =
                SurfaceComposerClient::getInternalDisplayId().value_or(
                        PhysicalDisplayId::fromPort(fdp->ConsumeIntegral<uint8_t>()));
        mFlinger->getHwComposer().allocatePhysicalDisplay(kHwDisplayId, physicalDisplayId);

        sp<IBinder> display =