Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Kuznetsov <kuzsasha@gmail.com>2012-05-02 01:46:55 +0400
committerAlexander Kuznetsov <kuzsasha@gmail.com>2012-05-02 01:46:55 +0400
commit274d3d2daa078645982a14399c07af8f084fdb3e (patch)
tree653b9dc787710a282299f71cfc3bc134faabb481 /source/blender/imbuf/intern/util.c
parent5cd4b32b3886798b795090d273a7c6f67195d176 (diff)
Fixes opening video files on Windows. [#30752]
Thanks Lockal for finding faulty stat function which helped a lot. Now there BLI_stat. I will replace all other stat later. *** Please use BLI_xxxx() functions *** for file operations Reported by Leon Cheung, Lockal, Believil
Diffstat (limited to 'source/blender/imbuf/intern/util.c')
-rw-r--r--source/blender/imbuf/intern/util.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/source/blender/imbuf/intern/util.c b/source/blender/imbuf/intern/util.c
index 62cf206dfec..99872192e32 100644
--- a/source/blender/imbuf/intern/util.c
+++ b/source/blender/imbuf/intern/util.c
@@ -40,6 +40,7 @@
#endif
#include "BLI_blenlib.h"
+#include "BLI_fileops.h"
#include "DNA_userdef_types.h"
#include "BKE_global.h"
@@ -342,14 +343,14 @@ int imb_get_anim_type(const char * name)
/* stat test below fails on large files > 4GB */
if (isffmpeg(name)) return (ANIM_FFMPEG);
# endif
- if (stat(name, &st) == -1) return(0);
+ if (BLI_stat(name, &st) == -1) return(0);
if (((st.st_mode) & S_IFMT) != S_IFREG) return(0);
if (isavi(name)) return (ANIM_AVI);
if (ismovie(name)) return (ANIM_MOVIE);
#else
- if (stat(name, &st) == -1) return(0);
+ if (BLI_stat(name, &st) == -1) return(0);
if (((st.st_mode) & S_IFMT) != S_IFREG) return(0);
if (ismovie(name)) return (ANIM_MOVIE);
@@ -359,6 +360,8 @@ int imb_get_anim_type(const char * name)
# ifdef WITH_FFMPEG
if (isffmpeg(name)) return (ANIM_FFMPEG);
# endif
+
+
if (isavi(name)) return (ANIM_AVI);
#endif
#ifdef WITH_REDCODE