Commit 3049e8a7 authored by melanson's avatar melanson

use the correct file modes


git-svn-id: file:///var/local/repositories/ffmpeg/trunk@2381 9553f0bf-9b14-0410-a0b8-cfaf0461ba5b
parent 366d7b03
...@@ -94,7 +94,7 @@ int main(int argc, char **argv) ...@@ -94,7 +94,7 @@ int main(int argc, char **argv)
exit(1); exit(1);
} }
outfile = fopen(argv[1], "w"); outfile = fopen(argv[1], "wb");
if (!outfile) { if (!outfile) {
perror(argv[1]); perror(argv[1]);
return 1; return 1;
......
...@@ -92,7 +92,7 @@ void pgmyuv_save(const char *filename, int w, int h, ...@@ -92,7 +92,7 @@ void pgmyuv_save(const char *filename, int w, int h,
rgb24_to_yuv420p(lum_tab, cb_tab, cr_tab, rgb_tab, w, h); rgb24_to_yuv420p(lum_tab, cb_tab, cr_tab, rgb_tab, w, h);
f = fopen(filename,"w"); f = fopen(filename,"wb");
fprintf(f, "P5\n%d %d\n%d\n", w, (h * 3) / 2, 255); fprintf(f, "P5\n%d %d\n%d\n", w, (h * 3) / 2, 255);
fwrite(lum_tab, 1, w * h, f); fwrite(lum_tab, 1, w * h, f);
h2 = h / 2; h2 = h / 2;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment