[MPlayer-cvslog] r21460 - trunk/vobsub.c

reimar subversion at mplayerhq.hu
Sun Dec 3 12:23:04 CET 2006


Author: reimar
Date: Sun Dec  3 12:23:04 2006
New Revision: 21460

Modified:
   trunk/vobsub.c

Log:
Open vobsub output files in binary mode, otherwise the OS might
do all kinds of evil mangling to them (fixes bug #668).


Modified: trunk/vobsub.c
==============================================================================
--- trunk/vobsub.c	(original)
+++ trunk/vobsub.c	Sun Dec  3 12:23:04 2006
@@ -1357,12 +1357,12 @@
 	    result->aid = index;
 	    strcpy(filename, basename);
 	    strcat(filename, ".sub");
-	    result->fsub = fopen(filename, "a");
+	    result->fsub = fopen(filename, "ab");
 	    if (result->fsub == NULL)
 		perror("Error: vobsub_out_open subtitle file open failed");
 	    strcpy(filename, basename);
 	    strcat(filename, ".idx");
-	    result->fidx = fopen(filename, "a");
+	    result->fidx = fopen(filename, "ab");
 	    if (result->fidx) {
 		if (ftell(result->fidx) == 0){
 		    create_idx(result, palette, orig_width, orig_height);



More information about the MPlayer-cvslog mailing list