summaryrefslogtreecommitdiff
path: root/src/HttpServer.cc
diff options
context:
space:
mode:
authorPixel <pixel@nobis-crew.org>2011-12-05 09:16:42 -0800
committerPixel <pixel@nobis-crew.org>2011-12-05 09:16:42 -0800
commit2f36082049c30562f2cb3061438c4aaebc8d8fe5 (patch)
treec1a93f96750cce63e9801b0907499c8a4d2b969e /src/HttpServer.cc
parentb419f3e159212c9998b3f86c1fee332620472f4e (diff)
Adding read-write locks, and applying them immediately to the http server.
Diffstat (limited to 'src/HttpServer.cc')
-rw-r--r--src/HttpServer.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/HttpServer.cc b/src/HttpServer.cc
index d96dd2b..e2ff180 100644
--- a/src/HttpServer.cc
+++ b/src/HttpServer.cc
@@ -534,14 +534,14 @@ void Balau::HttpServer::stop() {
}
void Balau::HttpServer::registerAction(Action * action) {
- m_actionsLock.enter();
+ m_actionsLock.enterW();
action->ref();
m_actions.push_front(action);
m_actionsLock.leave();
}
void Balau::HttpServer::flushAllActions() {
- m_actionsLock.enter();
+ m_actionsLock.enterW();
Action * a;
while (!m_actions.empty()) {
a = m_actions.front();
@@ -563,7 +563,7 @@ Balau::HttpServer::Action::ActionMatch Balau::HttpServer::Action::matches(const
}
Balau::HttpServer::ActionFound Balau::HttpServer::findAction(const char * uri, const char * host) {
- m_actionsLock.enter();
+ m_actionsLock.enterR();
ActionList::iterator i;
ActionFound r;