mirror of
https://github.com/holub/mame
synced 2025-05-28 16:43:04 +03:00
Windows OSD / stdout/stderr output buffering [qmc2]
This commit is contained in:
parent
49dad77354
commit
b3b3257747
@ -45,6 +45,7 @@
|
||||
#include <commctrl.h>
|
||||
#include <mmsystem.h>
|
||||
#include <tchar.h>
|
||||
#include <io.h>
|
||||
|
||||
// standard C headers
|
||||
#include <ctype.h>
|
||||
@ -454,6 +455,12 @@ const options_entry windows_options::s_option_entries[] =
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
// use small output buffers on non-TTYs (i.e. pipes)
|
||||
if (!isatty(fileno(stdout)))
|
||||
setvbuf(stdout, (char *) NULL, _IOFBF, 64);
|
||||
if (!isatty(fileno(stderr)))
|
||||
setvbuf(stderr, (char *) NULL, _IOFBF, 64);
|
||||
|
||||
// initialize common controls
|
||||
InitCommonControls();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user