summaryrefslogtreecommitdiff
path: root/src/options.c
diff options
context:
space:
mode:
authorDaniel Friesel <derf@finalrewind.org>2021-03-05 21:25:15 +0100
committerDaniel Friesel <derf@finalrewind.org>2021-03-05 21:25:15 +0100
commit20c7b9d482e102984a721976e1904477ecbaf456 (patch)
tree44e54b7646d7318b38133f6cef6229b3204a37d9 /src/options.c
parentb2ce6d8b85cd05964f509c4e00587ac58e3696f3 (diff)
Set original_file_items when using --start-at without file arguments
This makes --(auto-)reload use the directory specified at --start-at instead of the current working directory. Closes #597
Diffstat (limited to 'src/options.c')
-rw-r--r--src/options.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/options.c b/src/options.c
index 04550b9..1a89d5b 100644
--- a/src/options.c
+++ b/src/options.c
@@ -898,6 +898,7 @@ static void feh_parse_option_array(int argc, char **argv, int finalrun)
*filename_start = '\0';
}
add_file_to_filelist_recursively(target_directory, FILELIST_FIRST);
+ original_file_items = gib_list_add_front(original_file_items, estrdup(target_directory));
free(target_directory);
} else {
add_file_to_filelist_recursively(".", FILELIST_FIRST);