summaryrefslogtreecommitdiff
path: root/src/HttpServerResponseCommand.cc
diff options
context:
space:
mode:
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2010-06-08 15:02:20 +0000
committerTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2010-06-08 15:02:20 +0000
commit9afc36152a1ce428243a3ace608d0508716a2efb (patch)
tree2e144d04570a058f3e2716d7b98f16803392cdbe /src/HttpServerResponseCommand.cc
parent7cd9b21937c42606354610c7ae85a0857b474cf5 (diff)
2010-06-09 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Made protected member variables of Command private. Added accessor funcs.
Diffstat (limited to 'src/HttpServerResponseCommand.cc')
-rw-r--r--src/HttpServerResponseCommand.cc27
1 files changed, 15 insertions, 12 deletions
diff --git a/src/HttpServerResponseCommand.cc b/src/HttpServerResponseCommand.cc
index dd464a97..4b98b193 100644
--- a/src/HttpServerResponseCommand.cc
+++ b/src/HttpServerResponseCommand.cc
@@ -76,29 +76,32 @@ bool HttpServerResponseCommand::execute()
try {
_httpServer->sendResponse();
} catch(RecoverableException& e) {
- if(logger->info()) {
- logger->info("CUID#%s - Error occurred while transmitting response body.",
- e, util::itos(cuid).c_str());
+ if(getLogger()->info()) {
+ getLogger()->info
+ ("CUID#%s - Error occurred while transmitting response body.",
+ e, util::itos(getCuid()).c_str());
}
return true;
}
if(_httpServer->sendBufferIsEmpty()) {
- if(logger->info()) {
- logger->info("CUID#%s - HttpServer: all response transmitted.",
- util::itos(cuid).c_str());
+ if(getLogger()->info()) {
+ getLogger()->info("CUID#%s - HttpServer: all response transmitted.",
+ util::itos(getCuid()).c_str());
}
if(_httpServer->supportsPersistentConnection()) {
- if(logger->info()) {
- logger->info("CUID#%s - Persist connection.", util::itos(cuid).c_str());
+ if(getLogger()->info()) {
+ getLogger()->info("CUID#%s - Persist connection.",
+ util::itos(getCuid()).c_str());
}
- _e->addCommand(new HttpServerCommand(cuid, _httpServer, _e, _socket));
+ _e->addCommand
+ (new HttpServerCommand(getCuid(), _httpServer, _e, _socket));
}
return true;
} else {
if(_timeoutTimer.difference(global::wallclock) >= 10) {
- if(logger->info()) {
- logger->info("CUID#%s - HttpServer: Timeout while trasmitting"
- " response.", util::itos(cuid).c_str());
+ if(getLogger()->info()) {
+ getLogger()->info("CUID#%s - HttpServer: Timeout while trasmitting"
+ " response.", util::itos(getCuid()).c_str());
}
return true;
} else {