OSDN Git Service
(root)
/
android-x86
/
frameworks-base.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a33e3f7
)
attempt to work around [2155085, 2150246] stuck in closeTransaction()
author
Mathias Agopian
<mathias@google.com>
Wed, 30 Sep 2009 21:42:13 +0000
(14:42 -0700)
committer
Mathias Agopian
<mathias@google.com>
Wed, 30 Sep 2009 22:15:07 +0000
(15:15 -0700)
libs/surfaceflinger/SurfaceFlinger.cpp
patch
|
blob
|
history
diff --git
a/libs/surfaceflinger/SurfaceFlinger.cpp
b/libs/surfaceflinger/SurfaceFlinger.cpp
index
e468b23
..
eb0983a
100644
(file)
--- a/
libs/surfaceflinger/SurfaceFlinger.cpp
+++ b/
libs/surfaceflinger/SurfaceFlinger.cpp
@@
-1125,7
+1125,14
@@
void SurfaceFlinger::closeGlobalTransaction()
// take effect before returning.
Mutex::Autolock _l(mStateLock);
while (mResizeTransationPending) {
- mTransactionCV.wait(mStateLock);
+ status_t err = mTransactionCV.waitRelative(mStateLock, s2ns(5));
+ if (CC_UNLIKELY(err != NO_ERROR)) {
+ // just in case something goes wrong in SF, return to the
+ // called after a few seconds.
+ LOGW_IF(err == TIMED_OUT, "closeGlobalTransaction timed out!");
+ mResizeTransationPending = false;
+ break;
+ }
}
}
}