Apply [#26311] Collada Exporter Crash on Win64 build
Submitted by Filiciss Muhgue Selecting COLLADA export after starting blender into default scene Blender would crash, due to misreading the path string (no file saved yet, so it was zero).
This commit is contained in:
@@ -1392,9 +1392,12 @@ int BLI_replace_extension(char *path, int maxlen, const char *ext)
|
||||
{
|
||||
unsigned int a;
|
||||
|
||||
for(a=strlen(path)-1; a>=0; a--)
|
||||
if(path[a] == '.' || path[a] == '/' || path[a] == '\\')
|
||||
for(a=strlen(path); a>0; a--) {
|
||||
if(path[a-1] == '.' || path[a-1] == '/' || path[a-1] == '\\') {
|
||||
a--;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if(path[a] != '.')
|
||||
a= strlen(path);
|
||||
|
Reference in New Issue
Block a user