projects
/
sdk
/
tools
/
profctl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4d1e7a6
)
reduce CPU usage using sleep in main loop
author
Alexey Chernobaev
<achernobaev@dev.rtsoft.ru>
Wed, 29 Aug 2018 10:37:06 +0000
(13:37 +0300)
committer
Aleksei Vereshchagin
<avereschagin@dev.rtsoft.ru>
Mon, 3 Sep 2018 15:21:42 +0000
(18:21 +0300)
profctl.c
patch
|
blob
|
history
diff --git
a/profctl.c
b/profctl.c
index
7381088
..
5cc9020
100644
(file)
--- a/
profctl.c
+++ b/
profctl.c
@@
-718,6
+718,8
@@
int main(int argc, char **argv)
{
break; // data output thread finished
}
+ // sleep to reduce CPU usage
+ usleep(100 * 1000); // 100 msec
}
if (verbose && !global_stop) {
log_message("stop flag set (main)");