From 14f57cad7851d0d6c100412411a964031656bfad Mon Sep 17 00:00:00 2001 From: twinaphex Date: Sun, 10 Sep 2017 01:03:26 +0200 Subject: [PATCH] tmp_append_path freed too soon --- configuration.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configuration.c b/configuration.c index 1e73a94b32..4fc23eae5b 100644 --- a/configuration.c +++ b/configuration.c @@ -2264,8 +2264,6 @@ static bool config_load_file(const char *path, bool set_defaults, path_size); extra_path = strtok_r(tmp_append_path, "|", &save); - free(tmp_append_path); - while (extra_path) { bool ret = config_append_file(conf, extra_path); @@ -2276,6 +2274,8 @@ static bool config_load_file(const char *path, bool set_defaults, RARCH_ERR("Config: failed to append config \"%s\"\n", extra_path); extra_path = strtok_r(NULL, "|", &save); } + + free(tmp_append_path); } #if 0