Code Review
/
openocd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
6178055
)
logging: turn of stdout/stderr buffering
author
Øyvind Harboe
<oyvind.harboe@zylin.com>
Fri, 17 Sep 2010 23:37:42 +0000
(
01:37
+0200)
committer
Øyvind Harboe
<oyvind.harboe@zylin.com>
Mon, 20 Sep 2010 18:45:48 +0000
(20:45 +0200)
with this buffering disabled fancier logging scripts will
be able to process each line as it is output.
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
src/main.c
patch
|
blob
|
history
diff --git
a/src/main.c
b/src/main.c
index
a71977d
..
9c7191d
100644
(file)
--- a/
src/main.c
+++ b/
src/main.c
@@
-35,5
+35,9
@@
int main(int argc, char *argv[])
{
+ /* disable buffering otherwise piping to logs causes problems work */
+ setvbuf(stdout, NULL, _IONBF, 0);
+ setvbuf(stderr, NULL, _IONBF, 0);
+
return openocd_main(argc, argv);
}