diff --git a/libobs/obs-module.c b/libobs/obs-module.c index 84b2848c0..a9ac5d0d4 100644 --- a/libobs/obs-module.c +++ b/libobs/obs-module.c @@ -193,13 +193,8 @@ static char *make_data_directory(const char *module_name, const char *data_dir) found = os_file_exists(parsed_data_dir.array); - if (!found && astrcmpi_n(module_name, "lib", 3) == 0) { + if (!found && astrcmpi_n(module_name, "lib", 3) == 0) make_data_dir(&parsed_data_dir, data_dir, module_name + 3); - found = os_file_exists(parsed_data_dir.array); - } - - if (!found) - dstr_free(&parsed_data_dir); return parsed_data_dir.array; }