diff options
author | Ryan Dwyer <RyanDwyer@users.noreply.github.com> | 2018-12-09 21:50:19 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-12-09 21:50:19 +1000 |
commit | b61a936c8060bc4ac4320a5f76fd98b5042e5e41 (patch) | |
tree | 279a5554686d6e862282c943bda50787b69711e1 /sway/commands/reload.c | |
parent | e7efa0e27b7bf44217d7f147281d463708d2dfc9 (diff) | |
parent | 98c1e19466c0d83c8e1ca86eda5b273eda7eff3c (diff) |
Merge pull request #3271 from ianyfan/list-cleanup
list.c: Remove list_foreach
Diffstat (limited to 'sway/commands/reload.c')
-rw-r--r-- | sway/commands/reload.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sway/commands/reload.c b/sway/commands/reload.c index c64de4bd..3ccbbf34 100644 --- a/sway/commands/reload.c +++ b/sway/commands/reload.c @@ -24,8 +24,7 @@ static void do_reload(void *data) { if (!load_main_config(config->current_config_path, true, false)) { wlr_log(WLR_ERROR, "Error(s) reloading config"); - list_foreach(bar_ids, free); - list_free(bar_ids); + list_free_items_and_destroy(bar_ids); return; } @@ -42,9 +41,7 @@ static void do_reload(void *data) { } } } - - list_foreach(bar_ids, free); - list_free(bar_ids); + list_free_items_and_destroy(bar_ids); config_update_font_height(true); root_for_each_container(rebuild_textures_iterator, NULL); |