aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorkoekeishiya <aasvi93@hotmail.com>2018-08-30 15:48:41 +0200
committerkoekeishiya <aasvi93@hotmail.com>2018-08-30 15:48:41 +0200
commit40bc9b361d655348b182af061adf2cc374f737b5 (patch)
tree39318e39c8a098fc579115e97d4a7e9ec6e27995 /src
parentf8e4925d683530f04f432fe9998d0e53b907dbec (diff)
downloadskhd-40bc9b361d655348b182af061adf2cc374f737b5.tar.gz
skhd-40bc9b361d655348b182af061adf2cc374f737b5.zip
properly free memory allocated for process_names and commands
Diffstat (limited to 'src')
-rw-r--r--src/hotkey.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/hotkey.c b/src/hotkey.c
index 7b3008a..10d5f5e 100644
--- a/src/hotkey.c
+++ b/src/hotkey.c
@@ -197,10 +197,12 @@ void free_mode_map(struct table *mode_map)
for (int i = 0; i < buf_len(hotkey->process_name); ++i) {
free(hotkey->process_name[i]);
}
+ buf_free(hotkey->process_name);
for (int i = 0; i < buf_len(hotkey->command); ++i) {
free(hotkey->command[i]);
}
+ buf_free(hotkey->command);
free(hotkey);
next:;