aboutsummaryrefslogtreecommitdiff
path: root/sway
diff options
context:
space:
mode:
Diffstat (limited to 'sway')
-rw-r--r--sway/commands/bar/modifier.c4
-rw-r--r--sway/commands/bind.c6
-rw-r--r--sway/commands/reload.c4
-rw-r--r--sway/commands/workspace.c2
-rw-r--r--sway/config.c8
-rw-r--r--sway/config/bar.c2
-rw-r--r--sway/tree/container.c2
-rw-r--r--sway/tree/workspace.c2
8 files changed, 15 insertions, 15 deletions
diff --git a/sway/commands/bar/modifier.c b/sway/commands/bar/modifier.c
index 1b3e7492..b5a16f45 100644
--- a/sway/commands/bar/modifier.c
+++ b/sway/commands/bar/modifier.c
@@ -23,11 +23,11 @@ struct cmd_results *bar_cmd_modifier(int argc, char **argv) {
} else {
error = cmd_results_new(CMD_INVALID, "modifier",
"Unknown modifier '%s'", split->items[i]);
- free_flat_list(split);
+ list_free_items_and_destroy(split);
return error;
}
}
- free_flat_list(split);
+ list_free_items_and_destroy(split);
config->current_bar->modifier = mod;
wlr_log(WLR_DEBUG,
"Show/Hide the bar when pressing '%s' in hide mode.", argv[0]);
diff --git a/sway/commands/bind.c b/sway/commands/bind.c
index 886a262c..01a35cf2 100644
--- a/sway/commands/bind.c
+++ b/sway/commands/bind.c
@@ -23,7 +23,7 @@ void free_sway_binding(struct sway_binding *binding) {
return;
}
- free_flat_list(binding->keys);
+ list_free_items_and_destroy(binding->keys);
free(binding->input);
free(binding->command);
free(binding);
@@ -220,14 +220,14 @@ static struct cmd_results *cmd_bindsym_or_bindcode(int argc, char **argv,
uint32_t *key = calloc(1, sizeof(uint32_t));
if (!key) {
free_sway_binding(binding);
- free_flat_list(split);
+ list_free_items_and_destroy(split);
return cmd_results_new(CMD_FAILURE, bindtype,
"Unable to allocate binding key");
}
*key = key_val;
list_add(binding->keys, key);
}
- free_flat_list(split);
+ list_free_items_and_destroy(split);
binding->order = binding_order++;
// refine region of interest for mouse binding once we are certain
diff --git a/sway/commands/reload.c b/sway/commands/reload.c
index c236911e..3ccbbf34 100644
--- a/sway/commands/reload.c
+++ b/sway/commands/reload.c
@@ -24,7 +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");
- free_flat_list(bar_ids);
+ list_free_items_and_destroy(bar_ids);
return;
}
@@ -41,7 +41,7 @@ static void do_reload(void *data) {
}
}
}
- free_flat_list(bar_ids);
+ list_free_items_and_destroy(bar_ids);
config_update_font_height(true);
root_for_each_container(rebuild_textures_iterator, NULL);
diff --git a/sway/commands/workspace.c b/sway/commands/workspace.c
index 7d32e65b..211b344d 100644
--- a/sway/commands/workspace.c
+++ b/sway/commands/workspace.c
@@ -33,7 +33,7 @@ static struct workspace_config *workspace_config_find_or_create(char *ws_name) {
void free_workspace_config(struct workspace_config *wsc) {
free(wsc->workspace);
- free_flat_list(wsc->outputs);
+ list_free_items_and_destroy(wsc->outputs);
free(wsc);
}
diff --git a/sway/config.c b/sway/config.c
index 4621cad9..5b03bc56 100644
--- a/sway/config.c
+++ b/sway/config.c
@@ -444,7 +444,7 @@ bool load_main_config(const char *file, bool is_active, bool validating) {
}
}
- free_flat_list(secconfigs);
+ list_free_items_and_destroy(secconfigs);
}
*/
@@ -652,7 +652,7 @@ bool read_config(FILE *file, struct sway_config *config,
if (read + length > config_size) {
wlr_log(WLR_ERROR, "Config file changed during reading");
- free_flat_list(stack);
+ list_free_items_and_destroy(stack);
free(line);
return false;
}
@@ -681,7 +681,7 @@ bool read_config(FILE *file, struct sway_config *config,
}
char *expanded = expand_line(block, line, brace_detected > 0);
if (!expanded) {
- free_flat_list(stack);
+ list_free_items_and_destroy(stack);
free(line);
return false;
}
@@ -746,7 +746,7 @@ bool read_config(FILE *file, struct sway_config *config,
free(line);
free_cmd_results(res);
}
- free_flat_list(stack);
+ list_free_items_and_destroy(stack);
config->current_config_line_number = 0;
config->current_config_line = NULL;
diff --git a/sway/config/bar.c b/sway/config/bar.c
index fc773026..45c9e998 100644
--- a/sway/config/bar.c
+++ b/sway/config/bar.c
@@ -52,7 +52,7 @@ void free_bar_config(struct bar_config *bar) {
free_bar_binding(bar->bindings->items[i]);
}
list_free(bar->bindings);
- free_flat_list(bar->outputs);
+ list_free_items_and_destroy(bar->outputs);
if (bar->pid != 0) {
terminate_swaybar(bar->pid);
}
diff --git a/sway/tree/container.c b/sway/tree/container.c
index ac433577..b106e0d9 100644
--- a/sway/tree/container.c
+++ b/sway/tree/container.c
@@ -68,7 +68,7 @@ void container_destroy(struct sway_container *con) {
list_free(con->current.children);
list_free(con->outputs);
- free_flat_list(con->marks);
+ list_free_items_and_destroy(con->marks);
wlr_texture_destroy(con->marks_focused);
wlr_texture_destroy(con->marks_focused_inactive);
wlr_texture_destroy(con->marks_unfocused);
diff --git a/sway/tree/workspace.c b/sway/tree/workspace.c
index 4be63311..ed24b4fd 100644
--- a/sway/tree/workspace.c
+++ b/sway/tree/workspace.c
@@ -142,7 +142,7 @@ void workspace_destroy(struct sway_workspace *workspace) {
free(workspace->name);
free(workspace->representation);
- free_flat_list(workspace->output_priority);
+ list_free_items_and_destroy(workspace->output_priority);
list_free(workspace->floating);
list_free(workspace->tiling);
list_free(workspace->current.floating);