summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryn M. Reeves <bmr@redhat.com>2015-08-08 17:31:36 +0100
committerBryn M. Reeves <bmr@redhat.com>2015-08-08 17:48:30 +0100
commit3638c05ec95e0fa445f06b05567189b712a0b8a9 (patch)
tree4df52257cb53a22ad4752b59351f280857258036
parent54815fff0694ab562d041a4de1ee54ac0cd10f48 (diff)
downloadlvm2-3638c05ec95e0fa445f06b05567189b712a0b8a9.tar.gz
libdm: do not attempt to output column headings with --rows
Columns-as-rows output does not use _report_headings(); don't try to call it when rh->flags & DM_REPORT_OUTPUT_COLUMNS_AS_ROWS.
-rw-r--r--libdm/libdm-report.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libdm/libdm-report.c b/libdm/libdm-report.c
index de87ca468..17a7e13b2 100644
--- a/libdm/libdm-report.c
+++ b/libdm/libdm-report.c
@@ -3994,6 +3994,9 @@ static int _report_headings(struct dm_report *rh)
int dm_report_column_headings(struct dm_report *rh)
{
+ /* Columns-as-rows does not use _report_headings. */
+ if (rh->flags & DM_REPORT_OUTPUT_COLUMNS_AS_ROWS)
+ return 1;
return _report_headings(rh);
}