diff options
author | Pixel <pixel@nobis-crew.org> | 2011-11-16 08:17:05 -0800 |
---|---|---|
committer | Pixel <pixel@nobis-crew.org> | 2011-11-16 08:17:05 -0800 |
commit | 4908625aa005082cbbc43a63dc9d2c508eaaccf2 (patch) | |
tree | 16929acf6d28df4661e1c1e81a2688c9b16da2a7 /src | |
parent | b6c30682c3bba2e9c9fae9614e420d9c60e1ed25 (diff) |
Using the new WriteOnly class in the HttpServer, to protect the socket from being read, as it needs to go thru the BStream.
Diffstat (limited to 'src')
-rw-r--r-- | src/HttpServer.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/HttpServer.cc b/src/HttpServer.cc index dbc9b92..ef7e5bc 100644 --- a/src/HttpServer.cc +++ b/src/HttpServer.cc @@ -13,7 +13,7 @@ typedef std::map<String, String> StringMap; class HttpWorker : public Task { public: - HttpWorker(IO<Socket> & io, void * server); + HttpWorker(IO<Handle> io, void * server); ~HttpWorker(); private: virtual void Do(); @@ -31,7 +31,7 @@ class HttpWorker : public Task { }; -Balau::HttpWorker::HttpWorker(IO<Socket> & io, void * _server) : m_socket(io), m_strm(new BStream(io)) { +Balau::HttpWorker::HttpWorker(IO<Handle> io, void * _server) : m_socket(new WriteOnly(io)), m_strm(new BStream(io)) { HttpServer * server = (HttpServer *) _server; m_name.set("HttpWorker(%s)", m_socket->getName()); // copy stuff from server, such as port number, root document, base URL, etc... |