summaryrefslogtreecommitdiff
path: root/server/src/session.h
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2011-11-28 15:03:17 +0100
committerBent Bisballe Nyeng <deva@aasimon.org>2011-11-28 15:03:17 +0100
commit2a89f766b3c4917001de03a06bfbecb1ce25675f (patch)
tree03f2e68488a5dad0619651c771912e8759fddfdc /server/src/session.h
parentdd1fb6e16ff777d3e098076d1015c6c565b51bb7 (diff)
Use one-thread-per-connection and fix up Session locking.
Diffstat (limited to 'server/src/session.h')
-rw-r--r--server/src/session.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/server/src/session.h b/server/src/session.h
index b5c31d7..4d1ed12 100644
--- a/server/src/session.h
+++ b/server/src/session.h
@@ -95,14 +95,14 @@ public:
* Create a new session, with a unique id. Insert it into the session list,
* and return its pointer.
*/
- Session *newSession(std::string patientid, std::string templ)
+ Session *newLockedSession(std::string patientid, std::string templ)
throw(SessionAlreadyActive);
/**
* Lookup session in session list. Returns the session or NULL if no session
* exists with that sessionid.
*/
- Session *session(std::string sessionid);
+ Session *lockedSession(std::string sessionid);
/**
* Remove session from the session list and return its pointer. It is up to
@@ -136,13 +136,13 @@ private:
Mutex mutex;
};
-class SessionAutolock {
+class SessionAutounlock {
public:
- SessionAutolock(Session &session);
- ~SessionAutolock();
+ SessionAutounlock(Session **session);
+ ~SessionAutounlock();
private:
- Session &session;
+ Session **session;
};
#endif/*__PRACRO_SESSION_H__*/