From: Robert Kessl Date: Thu, 10 Jul 2014 08:17:17 +0000 (+0200) Subject: tableprinter: update of size units X-Git-Tag: v6.1~3^2~103 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=fc223a2e13d6a03e944e5f8ce8207fe2303523b5;p=libucw.git tableprinter: update of size units --- diff --git a/ucw/table-test-2.c b/ucw/table-test-2.c index e4a06830..8b58dfa9 100644 --- a/ucw/table-test-2.c +++ b/ucw/table-test-2.c @@ -37,24 +37,24 @@ static void do_test(void) table_col_timestamp(tbl, TEST_COL1_TS, test_time); table_end_row(tbl); - tbl->column_order[TEST_COL0_SIZE].output_type = UNIT_SIZE_KILOBYTE; + tbl->column_order[TEST_COL0_SIZE].output_type = SIZE_UNIT_KILOBYTE; table_col_size(tbl, TEST_COL0_SIZE, test_size); table_col_timestamp(tbl, TEST_COL1_TS, test_time); table_end_row(tbl); - tbl->column_order[TEST_COL0_SIZE].output_type = UNIT_SIZE_MEGABYTE; + tbl->column_order[TEST_COL0_SIZE].output_type = SIZE_UNIT_MEGABYTE; table_col_size(tbl, TEST_COL0_SIZE, test_size); table_col_timestamp(tbl, TEST_COL1_TS, test_time); table_end_row(tbl); - tbl->column_order[TEST_COL0_SIZE].output_type = UNIT_SIZE_GIGABYTE; + tbl->column_order[TEST_COL0_SIZE].output_type = SIZE_UNIT_GIGABYTE; tbl->column_order[TEST_COL1_TS].output_type = TIMESTAMP_DATETIME; table_col_size(tbl, TEST_COL0_SIZE, test_size); table_col_timestamp(tbl, TEST_COL1_TS, test_time); table_end_row(tbl); test_size = test_size * 1024LU; - tbl->column_order[TEST_COL0_SIZE].output_type = UNIT_SIZE_TERABYTE; + tbl->column_order[TEST_COL0_SIZE].output_type = SIZE_UNIT_TERABYTE; tbl->column_order[TEST_COL1_TS].output_type = TIMESTAMP_DATETIME; table_col_size(tbl, TEST_COL0_SIZE, test_size); table_col_timestamp(tbl, TEST_COL1_TS, test_time); @@ -68,7 +68,7 @@ static void do_test(void) static struct table_template test_tbl2 = { TBL_COLUMNS { - [TEST_COL0_SIZE] = TBL_COL_SIZE_FMT("size", 15, UNIT_SIZE_BYTE), + [TEST_COL0_SIZE] = TBL_COL_SIZE_FMT("size", 15, SIZE_UNIT_BYTE), [TEST_COL1_TS] = TBL_COL_TIMESTAMP("ts", 20), TBL_COL_END },