From e1f86edd9d134471d64b6804989061801c40f3e5 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 29 Apr 2008 23:31:13 +0000 Subject: Don't print "Properties:" header for ports with no properties. git-svn-id: http://svn.drobilla.net/lad/slv2@1183 a436a847-0d15-0410-975c-d299462d15a1 --- utils/lv2_inspect.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/utils/lv2_inspect.c b/utils/lv2_inspect.c index 5aa6a6b..200d7dc 100644 --- a/utils/lv2_inspect.c +++ b/utils/lv2_inspect.c @@ -79,14 +79,16 @@ print_port(SLV2Plugin p, uint32_t index) } SLV2Values properties = slv2_port_get_properties(p, port); - printf("\t\tProperties: "); + if (slv2_values_size(properties) > 0) + printf("\t\tProperties: "); for (unsigned i=0; i < slv2_values_size(properties); ++i) { if (i > 0) { printf("\n\t\t "); } printf("%s\n", slv2_value_as_uri(slv2_values_get_at(properties, i))); } - printf("\n"); + if (slv2_values_size(properties) > 0) + printf("\n"); slv2_values_free(properties); } -- cgit v1.2.1