]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
column: fix memory leak [coverity scan]
authorKarel Zak <kzak@redhat.com>
Tue, 20 Feb 2018 13:48:26 +0000 (14:48 +0100)
committerKarel Zak <kzak@redhat.com>
Tue, 20 Feb 2018 13:48:26 +0000 (14:48 +0100)
Signed-off-by: Karel Zak <kzak@redhat.com>
text-utils/column.c

index 5d8dd8415e74fb67cace9417ff5e4fd98d8b6491..89d46d280bd8ac4c7cc0e6e4d3022b6bcc94464f 100644 (file)
@@ -333,6 +333,9 @@ static void reorder_table(struct column_control *ctl)
                scols_table_move_column(ctl->tab, last, wanted[i]);
                last = wanted[i];
        }
+
+       free(wanted);
+       strv_free(order);
 }
 
 static void create_tree(struct column_control *ctl)