mirror of
https://github.com/amadvance/snapraid.git
synced 2026-11-23 00:16:32 -05:00
Change the flush logic for streams
Now stdout and stderr are always line buffered, and stdlog only flushed on request.
This commit is contained in:
parent
80d51384ac
commit
798de7ca99
16 changed files with 40 additions and 20 deletions
|
|
@ -957,6 +957,11 @@ int devquery(tommy_list* high, tommy_list* low, int operation)
|
|||
void os_init(int opt)
|
||||
{
|
||||
(void)opt;
|
||||
|
||||
/* set stdout and stderr as "line buffered" */
|
||||
/* this ensures that messages are mixed correctly */
|
||||
setvbuf(stdout, 0, _IOLBF, BUFSIZ);
|
||||
setvbuf(stderr, 0, _IOLBF, BUFSIZ);
|
||||
}
|
||||
|
||||
void os_done(void)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue