mirror of
https://github.com/abraunegg/onedrive
synced 2024-05-14 19:56:41 +02:00
fix excessive usage of CPU in monitor mode
This commit is contained in:
parent
b702afda50
commit
c2cdb24131
|
@ -155,7 +155,7 @@ int main(string[] args)
|
|||
log.log(e.msg);
|
||||
}
|
||||
};
|
||||
if (!downloadOnly) m.init(cfg, verbose);
|
||||
if (!downloadOnly) m.init(cfg);
|
||||
// monitor loop
|
||||
immutable auto checkInterval = dur!"seconds"(45);
|
||||
auto lastCheckTime = MonoTime.currTime();
|
||||
|
@ -173,9 +173,8 @@ int main(string[] args)
|
|||
}
|
||||
}
|
||||
GC.collect();
|
||||
} else {
|
||||
Thread.sleep(dur!"msecs"(100));
|
||||
}
|
||||
Thread.sleep(dur!"msecs"(500));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue