OSDN Git Service

SurfaceFlinger: Set the result of binderized screencapture
authorMike J. Chen <mjchen@google.com>
Tue, 30 Jul 2013 17:19:24 +0000 (10:19 -0700)
committerMike J. Chen <mjchen@google.com>
Tue, 30 Jul 2013 17:24:22 +0000 (10:24 -0700)
A recent change to screencapture to have the call to
IGraphicBufferProducer happen on the incoming binder
thread didn't set the result so the result was always
returned as NO_ERROR.

This made screencap fail on some devices (e.g. Wolfie)
which relies on some kind of fallback mechanism to
generate the screencap but the fallback mechanism
doesn't get triggered because the error isn't returned.

Bug: 9989385

Change-Id: I2aee91ea1034869fcbb0f49b9a0087c3cff43bbe
Signed-off-by: Mike J. Chen <mjchen@google.com>
services/surfaceflinger/SurfaceFlinger.cpp

index 850bb21..b0e4002 100644 (file)
@@ -2605,6 +2605,7 @@ public:
     }
 
     void exit(status_t result) {
+        this->result = result;
         exitPending = true;
         looper->sendMessage(this, Message(MSG_EXIT));
     }