From 82259a086ebdd5b766f2dbb52f8287495cc47616 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Mon, 23 Sep 2019 04:14:10 +0200 Subject: [PATCH] Make action_scan_directory safer - fill_pathname_join now doesn't have the same variable for arguments 1 and 2 --- menu/cbs/menu_cbs_scan.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/menu/cbs/menu_cbs_scan.c b/menu/cbs/menu_cbs_scan.c index b16020dab0..1c401fd56e 100644 --- a/menu/cbs/menu_cbs_scan.c +++ b/menu/cbs/menu_cbs_scan.c @@ -81,10 +81,10 @@ int action_scan_directory(const char *path, menu_entries_get_last_stack(&menu_path, NULL, NULL, NULL, NULL); - strlcpy(fullpath, menu_path, sizeof(fullpath)); - if (path) - fill_pathname_join(fullpath, fullpath, path, sizeof(fullpath)); + fill_pathname_join(fullpath, menu_path, path, sizeof(fullpath)); + else + strlcpy(fullpath, menu_path, sizeof(fullpath)); task_push_dbscan( settings->paths.directory_playlist,