diff options
author | Sybren A. Stüvel <sybren@blender.org> | 2021-09-23 15:41:06 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@blender.org> | 2021-09-23 15:42:14 +0300 |
commit | 059d01d42e049a5d4a42f81c8b860540127efeb6 (patch) | |
tree | 26a74971a5e4f68e2a173b2ba51c20c67082cf2d | |
parent | 83975965a797642eb0aece30c6a887061b34978d (diff) |
Fileops: call `BLI_path_slash_native()` in `BLI_dir_create_recursive()`
Make the Windows version of `BLI_dir_create_recursive()` call
`BLI_path_slash_native()` before it tries to handle the path. This
should make it possible to call it with non-native path separators.
This change was provided by our Windows platform maintainer @LazyDodo in
P2414, so I assume he agrees with this change.
-rw-r--r-- | source/blender/blenlib/intern/fileops.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/fileops.c b/source/blender/blenlib/intern/fileops.c index 532a29b8147..88fb67c5502 100644 --- a/source/blender/blenlib/intern/fileops.c +++ b/source/blender/blenlib/intern/fileops.c @@ -570,6 +570,7 @@ bool BLI_dir_create_recursive(const char *dirname) * blah1/blah2 (without slash) */ BLI_strncpy(tmp, dirname, sizeof(tmp)); + BLI_path_slash_native(tmp); BLI_path_slash_rstrip(tmp); /* check special case "c:\foo", don't try create "c:", harmless but prints an error below */ |