aboutsummaryrefslogtreecommitdiffstats
path: root/sway/commands/bind.c
diff options
context:
space:
mode:
authorLibravatar Ian Fan <ianfan0@gmail.com>2018-12-09 01:15:23 +0000
committerLibravatar Ian Fan <ianfan0@gmail.com>2018-12-09 01:15:38 +0000
commit98c1e19466c0d83c8e1ca86eda5b273eda7eff3c (patch)
treeb47ccc174669786e3a1df9569046886c23003a45 /sway/commands/bind.c
parentCleanup list code (diff)
downloadsway-98c1e19466c0d83c8e1ca86eda5b273eda7eff3c.tar.gz
sway-98c1e19466c0d83c8e1ca86eda5b273eda7eff3c.tar.zst
sway-98c1e19466c0d83c8e1ca86eda5b273eda7eff3c.zip
list.c: rename free_flat_list to list_free_items_and_destroy
Diffstat (limited to 'sway/commands/bind.c')
-rw-r--r--sway/commands/bind.c6
1 files changed, 3 insertions, 3 deletions
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) {
23 return; 23 return;
24 } 24 }
25 25
26 free_flat_list(binding->keys); 26 list_free_items_and_destroy(binding->keys);
27 free(binding->input); 27 free(binding->input);
28 free(binding->command); 28 free(binding->command);
29 free(binding); 29 free(binding);
@@ -220,14 +220,14 @@ static struct cmd_results *cmd_bindsym_or_bindcode(int argc, char **argv,
220 uint32_t *key = calloc(1, sizeof(uint32_t)); 220 uint32_t *key = calloc(1, sizeof(uint32_t));
221 if (!key) { 221 if (!key) {
222 free_sway_binding(binding); 222 free_sway_binding(binding);
223 free_flat_list(split); 223 list_free_items_and_destroy(split);
224 return cmd_results_new(CMD_FAILURE, bindtype, 224 return cmd_results_new(CMD_FAILURE, bindtype,
225 "Unable to allocate binding key"); 225 "Unable to allocate binding key");
226 } 226 }
227 *key = key_val; 227 *key = key_val;
228 list_add(binding->keys, key); 228 list_add(binding->keys, key);
229 } 229 }
230 free_flat_list(split); 230 list_free_items_and_destroy(split);
231 binding->order = binding_order++; 231 binding->order = binding_order++;
232 232
233 // refine region of interest for mouse binding once we are certain 233 // refine region of interest for mouse binding once we are certain