/frameworks/native/libs/gui/BufferQueue.cpp
if (mConnectedApi != NO_CONNECTED_API) {
659 ST_LOGE("connect: already connected (cur=%d, req=%d)",
660 mConnectedApi, api);
661 return -EINVAL;
662 }
surface.java
/**
* Release the local reference to the server-side surface.
* Always call release() when you're done with a Surface.
* This will make the surface invalid.
*/
public void release() {
synchronized (mLock) {
if (mNativeObject != 0) {
nativeRelease(mNativeObject);
setNativeObjectLocked(0);
}
}
}
if (mConnectedApi != NO_CONNECTED_API) {
659 ST_LOGE("connect: already connected (cur=%d, req=%d)",
660 mConnectedApi, api);
661 return -EINVAL;
662 }
surface.java
/**
* Release the local reference to the server-side surface.
* Always call release() when you're done with a Surface.
* This will make the surface invalid.
*/
public void release() {
synchronized (mLock) {
if (mNativeObject != 0) {
nativeRelease(mNativeObject);
setNativeObjectLocked(0);
}
}
}