summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2016-03-27 12:26:36 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2016-03-27 12:26:36 -0700
commitdf5eed3b7fce2853e331c7de5294668c5b376334 (patch)
treebe3a46e83c320e8117bccac451771686bf1aabb9 /src
parent7dfe7fff11d7c22404db9f72c77bdb930267c634 (diff)
parenteee0305d40d48a3612d49d7177d29947bf97a67a (diff)
Merge pull request #118 from nwellnhof/win-eol-fix2
Set stdin to binary mode on Windows
Diffstat (limited to 'src')
-rw-r--r--src/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index c44ba13..fa18e03 100644
--- a/src/main.c
+++ b/src/main.c
@@ -75,6 +75,7 @@ int main(int argc, char *argv[]) {
int options = CMARK_OPT_DEFAULT;
#if defined(_WIN32) && !defined(__CYGWIN__)
+ _setmode(_fileno(stdin), _O_BINARY);
_setmode(_fileno(stdout), _O_BINARY);
#endif