From ad9cbaf7772b7f0c10da7b595d05b34346c35224 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Tue, 25 Nov 2014 09:01:16 +0100 Subject: [PATCH] xbps-query: print 'source-revisions' obj as any other metadata obj. There's no reason to special case it anymore. --- bin/xbps-query/show-info-files.c | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/bin/xbps-query/show-info-files.c b/bin/xbps-query/show-info-files.c index 6f94ec5d..25b557f5 100644 --- a/bin/xbps-query/show-info-files.c +++ b/bin/xbps-query/show-info-files.c @@ -160,21 +160,6 @@ show_pkg_info_one(xbps_dictionary_t d, const char *keys) free(key); } -static void -print_srcrevs(const char *keyname, xbps_string_t obj, const char *bold, const char *reset) -{ - const char *str = xbps_string_cstring_nocopy(obj); - - printf("%s%s%s:\n ", bold, keyname, reset); - for (unsigned int i = 0; i < strlen(str); i++) { - if (str[i] == '\n') - printf("\n "); - else - putchar(str[i]); - } - putchar('\n'); -} - void show_pkg_info(xbps_dictionary_t dict) { @@ -203,11 +188,6 @@ show_pkg_info(xbps_dictionary_t dict) (strcmp(keyname, "links") == 0)) continue; - /* special case for source-revisions obj */ - if (strcmp(keyname, "source-revisions") == 0) { - print_srcrevs(keyname, obj, bold, reset); - continue; - } /* anything else */ print_value_obj(keyname, obj, NULL, bold, reset, false); }