lk_free: Free func_table
authorAlexey Gladkov <gladkov.alexey@gmail.com>
Mon, 25 Feb 2013 13:20:01 +0000 (17:20 +0400)
committerAlexey Gladkov <gladkov.alexey@gmail.com>
Mon, 25 Feb 2013 13:20:01 +0000 (17:20 +0400)
Signed-off-by: Alexey Gladkov <gladkov.alexey@gmail.com>
src/libkeymap/common.c

index 637d295..294a945 100644 (file)
@@ -53,4 +53,9 @@ lk_free(struct keymap *kmap)
                if (kmap->key_map[i] != NULL)
                        free(kmap->key_map[i]);
        }
+
+       for (i = 0; i < MAX_NR_FUNC; i++) {
+               if (kmap->func_table[i] != NULL)
+                       free(kmap->func_table[i]);
+       }
 }