get_index_dir passed in the wrong size, also remove strange use of BLI_path_split_dir_file which copied the directory into `file`, only to overwrite it with the `file` afterwards.
get_index_dir passed in the wrong size, also remove strange use of BLI_path_split_dir_file which copied the directory into `file`, only to overwrite it with the `file` afterwards.