diff options
author | Daniel Friesel <derf@finalrewind.org> | 2021-01-24 05:40:15 +0100 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2021-01-24 05:40:15 +0100 |
commit | d72a19e7a3d58a4f9b314559378b17d4a6590c17 (patch) | |
tree | 335361d45d129b2fba58d679cf98b3394b824764 /src | |
parent | 447e04ff0359cd590e8ac965faabc35078cf2287 (diff) |
free opt.start_list_at before NULLing it
Diffstat (limited to 'src')
-rw-r--r-- | src/slideshow.c | 2 | ||||
-rw-r--r-- | src/thumbnail.c | 1 |
2 files changed, 3 insertions, 0 deletions
diff --git a/src/slideshow.c b/src/slideshow.c index 3a3cd0a..9154d2d 100644 --- a/src/slideshow.c +++ b/src/slideshow.c @@ -57,6 +57,7 @@ void init_slideshow_mode(void) // Try finding an exact filename match first for (; l && opt.start_list_at; l = l->next) { if (!strcmp(opt.start_list_at, FEH_FILE(l->data)->filename)) { + free(opt.start_list_at); opt.start_list_at = NULL; break; } @@ -83,6 +84,7 @@ void init_slideshow_mode(void) current_filename = FEH_FILE(l->data)->filename; } if (!strcmp(start_at_filename, current_filename)) { + free(opt.start_list_at); opt.start_list_at = NULL; break; } diff --git a/src/thumbnail.c b/src/thumbnail.c index e7b05a8..9781027 100644 --- a/src/thumbnail.c +++ b/src/thumbnail.c @@ -411,6 +411,7 @@ void init_thumbnail_mode(void) else if (opt.start_list_at) { for (l = thumbnails; l; l = l->next) { if (!strcmp(opt.start_list_at, FEH_THUMB(l->data)->file->filename)) { + free(opt.start_list_at); opt.start_list_at = NULL; feh_thumbnail_select(winwid, FEH_THUMB(l->data)); break; |