desired behavior is line-buffering but on win32 msvcrt there is no such thing and
it becomes full-buffering which delays log/output enough to make it nonsensical.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@2415
b64f7644-9d1e-0410-96f1-
a4d463321fa5
int build;
char * version;
+/* win32 _IOLBF (line-buffering) is the same as _IOFBF (full-buffering).
+ * force it to unbuffered otherwise informative output is not easily parsed.
+ */
+#if defined( _WIN32 ) || defined( __MINGW32__ )
+ setvbuf( stdout, NULL, _IONBF, 0 );
+ setvbuf( stderr, NULL, _IONBF, 0 );
+#endif
+
audios = hb_list_init();
/* Parse command line */