diff options
author | Peter Rajnoha <prajnoha@redhat.com> | 2016-08-04 09:42:33 +0200 |
---|---|---|
committer | Peter Rajnoha <prajnoha@redhat.com> | 2016-08-09 18:24:45 +0200 |
commit | 9c2113928430e25a4cc7b68a94aca7d8388b3b60 (patch) | |
tree | b348757dfe467a70c18a4ad061c2b7db581b1743 /libdm/libdevmapper.h | |
parent | 5649834f7d62b9cba3b06c1b5d0dd425978f3ad2 (diff) | |
download | lvm2-9c2113928430e25a4cc7b68a94aca7d8388b3b60.tar.gz |
libdm: report: add dm_report_destroy_rows
Calling dm_report_destroy_rows makes it possible to destroy any report
content we have but at the same time it doesn't destroy the report
handle itself, thus it's possible to reuse that handle again for new
report content.
Functionally, this is the same as calling dm_report_output with the
report handle but omitting the output iself. This functionality may
be useful if we, for whatever reason, need to discard the report
content and start a fresh new one but with the same report configuration
and initialization and thus we can just reuse the existing handle.
Diffstat (limited to 'libdm/libdevmapper.h')
-rw-r--r-- | libdm/libdevmapper.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libdm/libdevmapper.h b/libdm/libdevmapper.h index 22700160a..844a45548 100644 --- a/libdm/libdevmapper.h +++ b/libdm/libdevmapper.h @@ -2907,6 +2907,11 @@ int dm_report_compact_given_fields(struct dm_report *rh, const char *fields); */ int dm_report_is_empty(struct dm_report *rh); +/* + * Destroy report content without doing output. + */ +void dm_report_destroy_rows(struct dm_report *rh); + int dm_report_output(struct dm_report *rh); /* |