Skip to content
This repository has been archived by the owner on Dec 8, 2024. It is now read-only.

Commit

Permalink
fix excessive usage of CPU in monitor mode
Browse files Browse the repository at this point in the history
  • Loading branch information
skilion committed Sep 9, 2018
1 parent b702afd commit c2cdb24
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/main.d
Original file line number Diff line number Diff line change
Expand Up @@ -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();
Expand All @@ -173,9 +173,8 @@ int main(string[] args)
}
}
GC.collect();
} else {
Thread.sleep(dur!"msecs"(100));
}
Thread.sleep(dur!"msecs"(500));
}
}

Expand Down

0 comments on commit c2cdb24

Please sign in to comment.