Code Review
/
common
/
thrift.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
791a57f
)
Fix locking bug in ThreadManager.
author
David Reiss
<dreiss@apache.org>
Tue, 10 Jun 2008 22:55:04 +0000
(22:55 +0000)
committer
David Reiss
<dreiss@apache.org>
Tue, 10 Jun 2008 22:55:04 +0000
(22:55 +0000)
It looks like the scheduler waits on monitor_, but the worker notifies
workerMonitor_. Also, it does so out of critical section.
git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@666361
13f79535
-47bb-0310-9956-
ffa450edef68
lib/cpp/src/concurrency/ThreadManager.cpp
patch
|
blob
|
history
diff --git
a/lib/cpp/src/concurrency/ThreadManager.cpp
b/lib/cpp/src/concurrency/ThreadManager.cpp
index
604602e
..
34acc4c
100644
(file)
--- a/
lib/cpp/src/concurrency/ThreadManager.cpp
+++ b/
lib/cpp/src/concurrency/ThreadManager.cpp
@@
-251,7
+251,7
@@
class ThreadManager::Worker: public Runnable {
thread that might be blocked on add. */
if (manager_->pendingTaskCountMax_ != 0 &&
manager_->tasks_.size() == manager_->pendingTaskCountMax_ - 1) {
- manager_->
workerM
onitor_.notify();
+ manager_->
m
onitor_.notify();
}
}
} else {