diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2013-06-25 18:48:30 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2013-06-25 18:48:30 +0400 |
commit | 40d4dfaba84fe0d5048cc847d5d249a35314b8ed (patch) | |
tree | 89346ba302d9d00b857b23b13b84e14cd8c6ba99 /source/blender/blenkernel | |
parent | 689ca4aef7228f910065d45e0648e802c17ab7c2 (diff) |
Fix #35824: finding missing files not working correct for filepaths with special
characters on Windows.
Replaced some uses of stat() by BLI_stat() to properly handle such filepaths.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/bpath.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/packedFile.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/bpath.c b/source/blender/blenkernel/intern/bpath.c index 6a51dadd28e..6699cbcff2d 100644 --- a/source/blender/blenkernel/intern/bpath.c +++ b/source/blender/blenkernel/intern/bpath.c @@ -235,7 +235,7 @@ static int findFileRecursive(char *filename_new, BLI_join_dirfile(path, sizeof(path), dirname, de->d_name); - if (stat(path, &status) != 0) + if (BLI_stat(path, &status) != 0) continue; /* cant stat, don't bother with this file, could print debug info here */ if (S_ISREG(status.st_mode)) { /* is file */ diff --git a/source/blender/blenkernel/intern/packedFile.c b/source/blender/blenkernel/intern/packedFile.c index af67ada7765..f97429d7e65 100644 --- a/source/blender/blenkernel/intern/packedFile.c +++ b/source/blender/blenkernel/intern/packedFile.c @@ -378,7 +378,7 @@ int checkPackedFile(const char *filename, PackedFile *pf) BLI_strncpy(name, filename, sizeof(name)); BLI_path_abs(name, G.main->name); - if (stat(name, &st)) { + if (BLI_stat(name, &st)) { ret_val = PF_NOFILE; } else if (st.st_size != pf->size) { |