From 334e5eba9ee01357ca8275708711881fd9fbc99b Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Mon, 22 Feb 2016 10:43:25 +0100 Subject: libsmartcols: fix scols_table_print_range() to print header References: https://github.com/karelzak/util-linux/issues/287 Signed-off-by: Karel Zak --- libsmartcols/src/table_print.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libsmartcols') diff --git a/libsmartcols/src/table_print.c b/libsmartcols/src/table_print.c index f65cce383..d6622be64 100644 --- a/libsmartcols/src/table_print.c +++ b/libsmartcols/src/table_print.c @@ -1339,7 +1339,7 @@ int scols_table_print_range( struct libscols_table *tb, } else scols_reset_iter(&itr, SCOLS_ITER_FORWARD); - if (itr.p == tb->tb_lines.next) { + if (!start || itr.p == tb->tb_lines.next) { rc = print_header(tb, buf); if (rc) goto done; -- cgit v1.2.3-55-g7522