dump callstack on Surface use error
Change-Id: I38e260dd47349b9af3a999dda683a083a94be16d
diff --git a/libs/surfaceflinger_client/Surface.cpp b/libs/surfaceflinger_client/Surface.cpp
index 9467a4c..6d82b5d 100644
--- a/libs/surfaceflinger_client/Surface.cpp
+++ b/libs/surfaceflinger_client/Surface.cpp
@@ -489,6 +489,9 @@
LOGE("[Surface] using an invalid surface, "
"identity=%u should be %d",
mIdentity, identity);
+ CallStack stack;
+ stack.update();
+ stack.dump("Surface");
return NO_INIT;
}
@@ -497,6 +500,9 @@
if (err != NO_ERROR) {
LOGE("surface (identity=%u) is invalid, err=%d (%s)",
mIdentity, err, strerror(-err));
+ CallStack stack;
+ stack.update();
+ stack.dump("Surface");
return err;
}