<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Sat, Feb 10, 2018 at 10:49 AM, Ma0 <span dir="ltr"><<a href="mailto:mateuszb@poczta.onet.pl" target="_blank">mateuszb@poczta.onet.pl</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"># HG changeset patch<br>
# User Ma0 <<a href="mailto:mateuszb@poczta.onet.pl">mateuszb@poczta.onet.pl</a>><br>
# Date 1518239805 -3600<br>
# Sat Feb 10 06:16:45 2018 +0100<br>
# Node ID c4d56ef3611d3c157ce81241b655e9<wbr>53d58308f2<br>
# Parent 1949157705cef7e6e97df116e2f716<wbr>36f4cb0025<br>
fix output to pipe on Windows<br>
<br>
diff -r 1949157705ce -r c4d56ef3611d source/output/raw.cpp<br>
--- a/source/output/raw.cpp Wed Jan 31 19:44:19 2018 +0530<br>
+++ b/source/output/raw.cpp Sat Feb 10 06:16:45 2018 +0100<br>
@@ -24,6 +24,14 @@<br>
<br>
#include "raw.h"<br>
<br>
+#if _WIN32<br>
+#include <io.h><br>
+#include <fcntl.h><br>
+#if defined(_MSC_VER)<br>
+#pragma warning(disable: 4996) // POSIX setmode and fileno deprecated<br>
+#endif<br>
+#endif<br>
+<br>
using namespace X265_NS;<br>
using namespace std;<br>
<br>
@@ -33,6 +41,9 @@<br>
if (!strcmp(fname, "-"))<br>
{<br>
ofs = stdout;<br>
+#if _WIN32<br>
+ setmode(fileno(stdout), O_BINARY);<br>
+#endif<br>
return;<br>
}<br>
ofs = x265_fopen(fname, "wb");<br>
______________________________<wbr>_________________<br>
x265-devel mailing list<br>
<a href="mailto:x265-devel@videolan.org">x265-devel@videolan.org</a><br>
<a href="https://mailman.videolan.org/listinfo/x265-devel" rel="noreferrer" target="_blank">https://mailman.videolan.org/<wbr>listinfo/x265-devel</a><br>
</blockquote></div><br></div><div class="gmail_extra"><br></div><div class="gmail_extra">Thanks. Pushed to default.</div></div>