stdin/stdout on Windows; so add a new system function called sys_setbinarymode which does it instead. Then find lots more binary mode flags which need setting.
14 lines
206 B
C
14 lines
206 B
C
#include "system.h"
|
|
#include <fcntl.h>
|
|
|
|
#if defined WIN32
|
|
#include <io.h>
|
|
#endif
|
|
|
|
void sys_setbinarymode(FILE* fp)
|
|
{
|
|
#if defined WIN32
|
|
setmode(fileno(fp), O_BINARY);
|
|
#endif
|
|
}
|
|
|