diff options
author | Andrea Weikert <elubie@gmx.net> | 2007-03-01 00:37:14 +0300 |
---|---|---|
committer | Andrea Weikert <elubie@gmx.net> | 2007-03-01 00:37:14 +0300 |
commit | c7ad7cd1b03e2a6a5ddc9399264b9bdd2527a60d (patch) | |
tree | cdedceaca97511af60f35795b1c0c76b9e587d99 /source/blender/python/BPY_menus.c | |
parent | a734d3cc27a381f0c37835c14653ff8802ebca14 (diff) |
=== bugfix ===
[ #6077 ] Scripts in sub-sub-folders of Blender's scripts folder won't run.
[ #5572 ] Scripts in sub-folders of Blender's scripts folder won't run
- I've added a function in blenlib to join two strings with a path separator in between.
- Willian, Campbell, please check if commit in BPY_menus is ok and test - thanks!
Diffstat (limited to 'source/blender/python/BPY_menus.c')
-rw-r--r-- | source/blender/python/BPY_menus.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/source/blender/python/BPY_menus.c b/source/blender/python/BPY_menus.c index 9b4a5721d4c..580d84aaa3c 100644 --- a/source/blender/python/BPY_menus.c +++ b/source/blender/python/BPY_menus.c @@ -865,14 +865,8 @@ static int bpymenu_ParseDir(char *dirname, char *parentdir, int is_userdir ) s = de->d_name; if (parentdir) { /* Join parentdir and de->d_name */ - short a = strlen(parentdir); - strcpy(subdir, parentdir); - strcpy(subdir + a+1, de->d_name); -#ifdef WIN32 - subdir[a] = '\\'; -#else - subdir[a] = '/'; -#endif + BLI_join_dirfile(subdir, parentdir, de->d_name); + s = subdir; } bpymenu_ParseFile(file, s, is_userdir); @@ -905,7 +899,8 @@ static int bpymenu_ParseDir(char *dirname, char *parentdir, int is_userdir ) } s = de->d_name; if (parentdir) { - BLI_make_file_string(NULL, subdir, parentdir, de->d_name); + /* Join parentdir and de->d_name */ + BLI_join_dirfile(subdir, parentdir, de->d_name); s = subdir; } if (bpymenu_ParseDir(path, s, is_userdir) == -1) { |