2008-09-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>

Added debug log for socket event.
	* src/AbstractCommand.cc
	* src/PeerAbstractCommand.cc
pull/1/head
Tatsuhiro Tsujikawa 2008-09-23 10:50:00 +00:00
parent 2522175ff1
commit dc6ef187b6
3 changed files with 11 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2008-09-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Added debug log for socket event.
* src/AbstractCommand.cc
* src/PeerAbstractCommand.cc
2008-09-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com> 2008-09-23 Tatsuhiro Tsujikawa <tujikawa at rednoah dot com>
Log microseconds. Log microseconds.

View File

@ -87,6 +87,8 @@ AbstractCommand::~AbstractCommand() {
} }
bool AbstractCommand::execute() { bool AbstractCommand::execute() {
logger->debug("CUID#%d - socket: read:%d, write:%d, hup:%d, err:%d",
cuid, _readEvent, _writeEvent, _hupEvent, _errorEvent);
try { try {
if(_requestGroup->downloadFinished() || _requestGroup->isHaltRequested()) { if(_requestGroup->downloadFinished() || _requestGroup->isHaltRequested()) {
//logger->debug("CUID#%d - finished.", cuid); //logger->debug("CUID#%d - finished.", cuid);

View File

@ -74,6 +74,9 @@ PeerAbstractCommand::~PeerAbstractCommand()
bool PeerAbstractCommand::execute() bool PeerAbstractCommand::execute()
{ {
logger->debug("CUID#%d -"
" socket: read:%d, write:%d, hup:%d, err:%d, noCheck:%d",
cuid, _readEvent, _writeEvent, _hupEvent, _errorEvent, noCheck);
if(exitBeforeExecute()) { if(exitBeforeExecute()) {
onAbort(); onAbort();
return true; return true;