From a3ad35cf3a3a28ee51c30b88bc439af8dce9f7e4 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Wed, 13 Mar 2013 17:16:47 +0000 Subject: Fix #34626: voxel data texture can't read > 2GB files on Windows. Also fixed BLI_fopen not being used for AVI movie files, which meant AVI read could fail reading a file from a path with special characters on Windows. --- source/blender/avi/intern/avi.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'source/blender/avi') diff --git a/source/blender/avi/intern/avi.c b/source/blender/avi/intern/avi.c index 3afcdb680ac..6a5e8a61bd8 100644 --- a/source/blender/avi/intern/avi.c +++ b/source/blender/avi/intern/avi.c @@ -41,9 +41,7 @@ #include "MEM_guardedalloc.h" #include "MEM_sys_types.h" -#ifdef WIN32 -# include "BLI_winstuff.h" -#endif +#include "BLI_fileops.h" #include "AVI_avi.h" #include "avi_intern.h" @@ -208,7 +206,7 @@ int AVI_is_avi(char *name) FILE *fp; int ret; - fp = fopen(name, "rb"); + fp = BLI_fopen(name, "rb"); if (fp == NULL) return 0; @@ -238,7 +236,7 @@ int AVI_is_avi(const char *name) DEBUG_PRINT("opening movie\n"); movie.type = AVI_MOVIE_READ; - movie.fp = fopen(name, "rb"); + movie.fp = BLI_fopen(name, "rb"); movie.offset_table = NULL; if (movie.fp == NULL) @@ -441,7 +439,7 @@ AviError AVI_open_movie(const char *name, AviMovie *movie) memset(movie, 0, sizeof(AviMovie)); movie->type = AVI_MOVIE_READ; - movie->fp = fopen(name, "rb"); + movie->fp = BLI_fopen(name, "rb"); movie->offset_table = NULL; if (movie->fp == NULL) @@ -765,7 +763,7 @@ AviError AVI_open_compress(char *name, AviMovie *movie, int streams, ...) int64_t junk_pos; movie->type = AVI_MOVIE_WRITE; - movie->fp = fopen(name, "wb"); + movie->fp = BLI_fopen(name, "wb"); movie->index_entries = 0; -- cgit v1.2.3