patch [#34103] path_util_split_dirstring.patch, path_util_split_dirstring_2.patch...
[blender.git] / source / blender / blenkernel / intern / font.c
index 3e1e55132d8ec7261dee2fcb9cc38a348f863020..e4170a37102b9721c4f401a50f2be6ba06552beb 100644 (file)
@@ -195,11 +195,7 @@ VFont *BKE_vfont_load(Main *bmain, const char *name)
                is_builtin = TRUE;
        }
        else {
-               char dir[FILE_MAXDIR];
-               
-               BLI_strncpy(dir, name, sizeof(dir));
-               BLI_splitdirstring(dir, filename);
-
+               BLI_split_file_part(name, filename, sizeof(filename));
                pf = newPackedFile(NULL, name, bmain->name);
                temp_pf = newPackedFile(NULL, name, bmain->name);