summaryrefslogtreecommitdiff
path: root/bin/bbackupd/BackupDaemon.cpp
diff options
context:
space:
mode:
authorChris Wilson <chris+github@qwirx.com>2014-12-21 13:38:51 +0000
committerChris Wilson <chris+github@qwirx.com>2014-12-21 13:38:51 +0000
commit409ae9e8af28609941ad7e29c17827a8cc479bff (patch)
tree9915d71ee814fde34652117397dc04c3e24cab3d /bin/bbackupd/BackupDaemon.cpp
parent9a18a4c09cc32e5ac3668c884a600136dfd97779 (diff)
Log start time of next backup when waiting with millisecond precision.
Helps to debug tests that depend on subsecond timing. Log time to wait on command socket in fractional seconds instead of raw box_time_t.
Diffstat (limited to 'bin/bbackupd/BackupDaemon.cpp')
-rw-r--r--bin/bbackupd/BackupDaemon.cpp12
1 files changed, 7 insertions, 5 deletions
diff --git a/bin/bbackupd/BackupDaemon.cpp b/bin/bbackupd/BackupDaemon.cpp
index cfaeeef6..32b7b2d6 100644
--- a/bin/bbackupd/BackupDaemon.cpp
+++ b/bin/bbackupd/BackupDaemon.cpp
@@ -584,13 +584,13 @@ void BackupDaemon::Run2()
{
BOX_INFO("Last backup was not successful, "
"next one starting at " <<
- FormatTime(mNextSyncTime, false));
+ FormatTime(mNextSyncTime, false, true));
}
else if (automaticBackup)
{
BOX_INFO("Automatic backups are enabled, "
"next one starting at " <<
- FormatTime(mNextSyncTime, false));
+ FormatTime(mNextSyncTime, false, true));
}
else
{
@@ -1965,8 +1965,9 @@ bool BackupDaemon::RunBackgroundTask(State state, uint64_t progress,
//
// Function
// Name: BackupDaemon::WaitOnCommandSocket(box_time_t, bool &, bool &)
-// Purpose: Waits on a the command socket for a time of UP TO the required time
-// but may be much less, and handles a command if necessary.
+// Purpose: Waits on a the command socket for a time of UP TO
+// the required time but may be much less, and handles
+// a command if necessary.
// Created: 18/2/04
//
// --------------------------------------------------------------------------
@@ -1983,7 +1984,8 @@ void BackupDaemon::WaitOnCommandSocket(box_time_t RequiredDelay, bool &DoSyncFla
return;
}
- BOX_TRACE("Wait on command socket, delay = " << RequiredDelay);
+ BOX_TRACE("Wait on command socket, delay = " <<
+ BOX_FORMAT_MICROSECONDS(RequiredDelay));
try
{