am f7576400: am dba919c5: Merge "ugly, temporary, workaroung for a problem where a binder thread spins forever" into jb-mr1-dev

* commit 'f757640049a2ae19ba5047362f7fee47d9fb8ab7':
  ugly, temporary, workaroung for a problem where a binder thread spins forever
This commit is contained in:
Dave Burke 2012-10-05 23:31:33 -07:00 committed by Android Git Automerger
commit dec6db5b47

View File

@ -482,6 +482,18 @@ void IPCThreadState::joinThreadPool(bool isMain)
if(result == TIMED_OUT && !isMain) {
break;
}
// HACK HACK HACK HACK HACK HACK HACK HACK HACK HACK HACK HACK HACK
// FIXME: we sometimes get unexplained EINVAL which causes this
// thread to spin forever. TEMPORARILY allow it to exit.
// We should probably assert on eng builds
if(result == -EINVAL && !isMain) {
ALOGE("**** THREAD %p (PID %d) ERROR (%d) LEAVING THE THREAD POOL\n",
(void*)pthread_self(), getpid(), result);
break;
}
// HACK HACK HACK HACK HACK HACK HACK HACK HACK HACK HACK HACK HACK
} while (result != -ECONNREFUSED && result != -EBADF);
LOG_THREADPOOL("**** THREAD %p (PID %d) IS LEAVING THE THREAD POOL err=%p\n",