From: Robert Kessl Date: Mon, 21 Jul 2014 07:06:00 +0000 (+0200) Subject: tableprinter: table_set_col_order_by_name now calls table_make_default_column_order X-Git-Tag: v6.1~3^2~80 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=252a0e01c46c87b132d57e4f8745feaba3144e25;p=libucw.git tableprinter: table_set_col_order_by_name now calls table_make_default_column_order --- diff --git a/ucw/table.c b/ucw/table.c index e81dcdd8..5260a565 100644 --- a/ucw/table.c +++ b/ucw/table.c @@ -244,12 +244,7 @@ int table_set_col_opt_default(struct table *tbl, int col_idx, const char *col_ar const char * table_set_col_order_by_name(struct table *tbl, const char *col_order_str) { if(col_order_str[0] == '*') { - int *col_order_int = alloca(sizeof(int) * tbl->column_count); - for(int i = 0; i < tbl->column_count; i++) { - col_order_int[i] = i; - } - table_set_col_order(tbl, col_order_int, tbl->column_count); - + table_make_default_column_order(tbl); return NULL; }