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:
authorCampbell Barton <ideasman42@gmail.com>2011-11-15 11:35:28 +0400
committerCampbell Barton <ideasman42@gmail.com>2011-11-15 11:35:28 +0400
commit697726468e52ce18deb4e75b92bbeaeb3af09518 (patch)
tree8e6a3ead3f428707cd3d4e0961f4fc42bf527ede /source/blender/blenlib
parentab3295db33ad0152986818cc36f171c52de66482 (diff)
fix for own error, BLI_replace_extension would strip the filename if there wasn't already an extension.
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r--source/blender/blenlib/intern/path_util.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/path_util.c b/source/blender/blenlib/intern/path_util.c
index 7c7d51e5907..08d9dfaeb9e 100644
--- a/source/blender/blenlib/intern/path_util.c
+++ b/source/blender/blenlib/intern/path_util.c
@@ -1414,6 +1414,10 @@ int BLI_replace_extension(char *path, size_t maxlen, const char *ext)
}
}
+ if (path[a] != '.') {
+ a= path_len;
+ }
+
if(a + ext_len >= maxlen)
return 0;