From 0529e781875068e21085f4ac748eb5ee5d6085b3 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Sun, 11 Apr 2010 08:28:22 +0000 Subject: 2010-04-11 Tatsuhiro Tsujikawa Use clock_gettime(CLOCK_MONOTONIC, ...) if it is available and usable to prevent from aria2 from being affected by system time change. --- src/FileAllocationCommand.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/FileAllocationCommand.cc') diff --git a/src/FileAllocationCommand.cc b/src/FileAllocationCommand.cc index aa1029b8..f3ca426a 100644 --- a/src/FileAllocationCommand.cc +++ b/src/FileAllocationCommand.cc @@ -45,6 +45,7 @@ #include "DownloadContext.h" #include "a2functional.h" #include "RecoverableException.h" +#include "wallclock.h" namespace aria2 { @@ -65,7 +66,7 @@ bool FileAllocationCommand::executeInternal() if(_fileAllocationEntry->finished()) { if(logger->debug()) { logger->debug(MSG_ALLOCATION_COMPLETED, - _timer.difference(), + _timer.difference(global::wallclock), util::itos(_requestGroup->getTotalLength(), true).c_str()); } _e->_fileAllocationMan->dropPickedEntry(); -- cgit