changeset 29027:9c1508cdb122

enable vp6 codec to read/write .fpf (passlogfile) fixes 2pass vp6 encoding on linux
author compn
date Wed, 25 Mar 2009 23:59:48 +0000
parents 17e9f67f086b
children f8db50af4035
files loader/win32.c
diffstat 1 files changed, 5 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/loader/win32.c	Wed Mar 25 23:32:27 2009 +0000
+++ b/loader/win32.c	Wed Mar 25 23:59:48 2009 +0000
@@ -63,6 +63,8 @@
 #include <sys/types.h>
 #include <dirent.h>
 #include <sys/time.h>
+#include <sys/stat.h>
+#include <sys/timeb.h>
 #ifdef	HAVE_KSTAT
 #include <kstat.h>
 #endif
@@ -3519,7 +3521,7 @@
 	free(tmp);
 	return result;
     }
-    if (strstr(cs1, "vp3"))
+    if (strstr(cs1, "vp3") || strstr(cs1, ".fpf"))
     {
 	int r;
 	int flg = 0;
@@ -3537,10 +3539,10 @@
 	    flg |= O_RDONLY;
 	else if (GENERIC_WRITE & i1)
 	{
-	    flg |= O_WRONLY;
+	    flg |= O_WRONLY | O_CREAT;
 	    printf("Warning: openning filename %s  %d (flags; 0x%x) for write\n", tmp, r, flg);
 	}
-	r=open(tmp, flg);
+	r=open(tmp, flg, S_IRWXU);
 	free(tmp);
 	return r;
     }