From d4c34e4231ca566ebbe67d829376f1114907dc40 Mon Sep 17 00:00:00 2001 From: Kalyan Kondapally Date: Sat, 28 Jan 2017 01:28:17 -0800 Subject: [PATCH] Fix surfaceflinger crash when not connected to an display. Surfaceflinger expects atleast one active config and GetActiveConfig to succeed. We should be returning true in GetActiveConfig call after setting the config but we returned false causing crashes in Surfaceflinger side. Jira: None. Test: No crashes seen when no display is connected. Signed-off-by: Kalyan Kondapally --- common/core/headless.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/core/headless.cpp b/common/core/headless.cpp index 0bef65c..f5a9c24 100644 --- a/common/core/headless.cpp +++ b/common/core/headless.cpp @@ -104,7 +104,7 @@ bool Headless::GetActiveConfig(uint32_t *config) { return false; config[0] = 0; - return false; + return true; } bool Headless::SetDpmsMode(uint32_t /*dpms_mode*/) { -- 2.11.0