return an error, as expected, when querying a disconnected display
Change-Id: I405a3a7bb42b9bbd2ec7bfe09e60e1b7acf7389d
This commit is contained in:
parent
38e623bc5c
commit
4c0751a1f6
@ -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);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user