mirror of
https://github.com/vgmstream/vgmstream.git
synced 2025-02-17 19:19:16 +01:00
make test's standard output binary under windows
git-svn-id: https://vgmstream.svn.sourceforge.net/svnroot/vgmstream@271 51a99a44-fe44-0410-b1ba-c3e57ba2b86b
This commit is contained in:
parent
5cd7897407
commit
6f3139a78d
11
test/test.c
11
test/test.c
@ -2,6 +2,10 @@
|
||||
#include <unistd.h>
|
||||
#include "../src/vgmstream.h"
|
||||
#include "../src/util.h"
|
||||
#ifdef WIN32
|
||||
#include <io.h>
|
||||
#include <fcntl.h>
|
||||
#endif
|
||||
|
||||
#define BUFSIZE 4000
|
||||
|
||||
@ -116,6 +120,13 @@ int main(int argc, char ** argv) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
#ifdef WIN32
|
||||
/* make stdout output work with windows */
|
||||
if (play) {
|
||||
_setmode(fileno(stdout),_O_BINARY);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (ignore_loop && force_loop) {
|
||||
fprintf(stderr,"-e and -i are incompatible\n");
|
||||
return 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user