Fix a race that could cause GL commands to be executed from the wrong thread.
Change-Id: Ia3d407f7bf2f5553f46cfdade70b7b0badb35beb
diff --git a/services/surfaceflinger/Layer.h b/services/surfaceflinger/Layer.h
index 128f93d..278d64e 100644
--- a/services/surfaceflinger/Layer.h
+++ b/services/surfaceflinger/Layer.h
@@ -82,7 +82,6 @@
virtual bool isSecure() const { return mSecure; }
virtual bool isProtected() const;
virtual sp<Surface> createSurface() const;
- virtual status_t ditch();
virtual void onRemoved();
// only for debugging
@@ -93,6 +92,7 @@
return mFreezeLock; }
protected:
+ virtual void destroy() const;
virtual void dump(String8& result, char* scratch, size_t size) const;
private: