Files
MINGW-packages/mingw-w64-twolame/0003-binary-stdin.all.patch
2014-07-15 21:42:15 +04:00

21 lines
522 B
Diff

--- twolame-0.3.13/frontend/audioin_raw.c.orig 2012-09-15 11:23:30 +0400
+++ twolame-0.3.13/frontend/audioin_raw.c 2012-09-15 11:28:13 +0400
@@ -25,6 +25,7 @@
#include <stdlib.h>
#include <string.h>
#include <errno.h>
+#include <fcntl.h>
#include "frontend.h"
@@ -94,6 +94,9 @@
if (strcmp(filename, "-") == 0) {
// Use STDIN
audioin->file = stdin;
+#if defined(_WIN32)
+ setmode (fileno (stdin), O_BINARY);
+#endif
} else {
audioin->file = fopen(filename, "rb");
}