]> git.sesse.net Git - vlc/commitdiff
WinCE: build dump and timeshift modules
authorGeoffroy Couprie <geo.couprie@gmail.com>
Fri, 10 Oct 2008 09:37:00 +0000 (11:37 +0200)
committerGeoffroy Couprie <geo.couprie@gmail.com>
Tue, 14 Oct 2008 08:12:09 +0000 (10:12 +0200)
modules/access_filter/dump.c
modules/access_filter/timeshift.c

index 50ccf9aa58b96cf5deaf05380f4cc81028f166d2..a6c51b9871727f255d15b94d479dd99177fdd9d1 100644 (file)
@@ -114,7 +114,12 @@ static int Open (vlc_object_t *obj)
         return VLC_ENOMEM;
     memset (p_sys, 0, sizeof (*p_sys));
 
+# ifndef UNDER_CE
     if ((p_sys->stream = tmpfile ()) == NULL)
+# else
+    char buf[75];
+    if(GetTempFileName("\\Temp\\","vlc",0,buf) || ((p_sys->stream = fopen(buf,"wb+")) ==NULL))
+#endif
     {
         msg_Err (access, "cannot create temporary file: %m");
         free (p_sys);
index df486743e31a5916687944c42d72568a23006d41..0a124baa8587671d27b401251cfae5288cf54996 100644 (file)
@@ -40,7 +40,7 @@
 
 #include <unistd.h>
 
-#ifdef WIN32
+#if defined (WIN32) && !defined (UNDER_CE)
 #  include <direct.h>                                        /* _wgetcwd  */
 #endif
 
@@ -579,7 +579,7 @@ static char *GetTmpFilePath( access_t *p_access )
 
     if( psz_dir == NULL )
     {
-#ifdef WIN32
+#if defined (WIN32) && !defined (UNDER_CE)
         DWORD ret = GetTempPathW (0, NULL);
         wchar_t wdir[ret + 3]; // can at least old "C:" + nul
         const wchar_t *pwdir = wdir;