mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-23 00:47:21 -06:00
Use coarse timestamp format
Since format in milliseconds doesn't add additional value and is slower than just seconds.
This commit is contained in:
@@ -35,7 +35,7 @@
|
||||
#include "base/bittorrent/sessionstatus.h"
|
||||
#include "base/profile.h"
|
||||
|
||||
const qint64 SAVE_INTERVAL = 15 * 60 * 1000;
|
||||
const qint64 SAVE_INTERVAL = 15 * 60; // seconds
|
||||
|
||||
using namespace BitTorrent;
|
||||
|
||||
@@ -84,7 +84,7 @@ void Statistics::gather()
|
||||
|
||||
void Statistics::save() const
|
||||
{
|
||||
const qint64 now = QDateTime::currentMSecsSinceEpoch();
|
||||
const qint64 now = QDateTime::currentSecsSinceEpoch();
|
||||
|
||||
if (!m_dirty || ((now - m_lastWrite) < SAVE_INTERVAL))
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user