Commit: ec9b836d3b5634ed06c0ae5e2461731bc43f34bf
Author: Campbell Barton
Date: Tue Mar 10 12:29:37 2020 +1100
Branches: master
https://developer.blender.org/rBec9b836d3b5634ed06c0ae5e2461731bc43f34bf
Fix T74579: Filename with '\' causes assert when browsing files
===================================================================
M source/blender/editors/space_file/filelist.c
===================================================================
diff --git a/source/blender/editors/space_file/filelist.c
b/source/blender/editors/space_file/filelist.c
index 948fa91718e..52db0d1852d 100644
--- a/source/blender/editors/space_file/filelist.c
+++ b/source/blender/editors/space_file/filelist.c
@@ -636,7 +636,12 @@ static bool is_hidden_dot_filename(const char *filename,
FileListInternEntry *fi
BLI_strncpy(tmp_filename, filename, sizeof(tmp_filename));
sep = tmp_filename + (sep - filename);
while (sep) {
+ /* This happens when a path contains 'ALTSEP', '\' on Unix for e.g.
+ * Supporting alternate slashes in paths is a bigger task involving
changes
+ * in many parts of the code, for now just prevent an assert, see
T74579. */
+#if 0
BLI_assert(sep[1] != '\0');
+#endif
if (is_hidden_dot_filename(sep + 1, file)) {
hidden = true;
break;
_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs