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

Commit 7afa3dce authored by Mathias Agopian's avatar Mathias Agopian Committed by Android Git Automerger
Browse files

am 4c0751a1: return an error, as expected, when querying a disconnected display

* commit '4c0751a1':
  return an error, as expected, when querying a disconnected display
parents 245cfe06 4c0751a1
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -536,6 +536,10 @@ status_t SurfaceFlinger::getDisplayInfo(const sp<IBinder>& display, DisplayInfo*
    }

    const HWComposer& hwc(getHwComposer());
    if (!hwc.isConnected(type)) {
        return NAME_NOT_FOUND;
    }

    float xdpi = hwc.getDpiX(type);
    float ydpi = hwc.getDpiY(type);