diff options
author | Pixel <pixel@nobis-crew.org> | 2011-11-25 00:04:05 -0800 |
---|---|---|
committer | Pixel <pixel@nobis-crew.org> | 2011-11-25 00:04:14 -0800 |
commit | 9329e059b2e560cb3222cee8f8fcf0906de2cf73 (patch) | |
tree | 58a3c61528d373e321c7b5b0a3c6605cd2e853b0 /includes/HttpServer.h | |
parent | bf8f22b1f5b990c82993a9466f1da7c5226b1f8e (diff) |
Consts are good.
Diffstat (limited to 'includes/HttpServer.h')
-rw-r--r-- | includes/HttpServer.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/includes/HttpServer.h b/includes/HttpServer.h index 51c119c..227faa4 100644 --- a/includes/HttpServer.h +++ b/includes/HttpServer.h @@ -20,7 +20,7 @@ class HttpServer { class Action { public: - Action(Regex & regex, Regex & host = Regexes::any) : m_regex(regex), m_host(host), m_refCount(0) { } + Action(const Regex & regex, const Regex & host = Regexes::any) : m_regex(regex), m_host(host), m_refCount(0) { } ~Action() { Assert(m_refCount == 0); } typedef std::pair<Regex::Captures, Regex::Captures> ActionMatch; ActionMatch matches(const char * uri, const char * host); @@ -29,7 +29,7 @@ class HttpServer { void registerMe(HttpServer * server) { server->registerAction(this); } virtual bool Do(HttpServer * server, Http::Request & req, ActionMatch & match, IO<Handle> out) throw (GeneralException) = 0; private: - Regex m_regex, m_host; + const Regex m_regex, m_host; volatile int m_refCount; }; |