aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2001-04-14 11:52:40 +0000
committerFrancois Pons <fpons@mandriva.com>2001-04-14 11:52:40 +0000
commit71eb1dc5f4c6375e9782a036b474ed401f7d67ee (patch)
tree0de3c0d225ca9c44030258c3f6e788759b89ad1e
parent6114ee30f3aeacdf58cbe40207027f70db4de098 (diff)
downloadrpmtools-71eb1dc5f4c6375e9782a036b474ed401f7d67ee.tar
rpmtools-71eb1dc5f4c6375e9782a036b474ed401f7d67ee.tar.gz
rpmtools-71eb1dc5f4c6375e9782a036b474ed401f7d67ee.tar.bz2
rpmtools-71eb1dc5f4c6375e9782a036b474ed401f7d67ee.tar.xz
rpmtools-71eb1dc5f4c6375e9782a036b474ed401f7d67ee.zip
fixed interactive mode with provides tag to return flags and version,
commented print_list no more used.
-rw-r--r--parsehdlist.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/parsehdlist.c b/parsehdlist.c
index b81142b..cfc54be 100644
--- a/parsehdlist.c
+++ b/parsehdlist.c
@@ -52,6 +52,7 @@ char *get_name(Header header, int_32 tag) {
return name;
}
+/*
static
void print_list(Header header, int_32 tag_name, char *format, char sep, char *name) {
int_32 type, count;
@@ -70,6 +71,7 @@ void print_list(Header header, int_32 tag_name, char *format, char sep, char *na
}
free(list);
}
+*/
static
void print_list_flags(Header header, int_32 tag_name, int_32 tag_flags, int_32 tag_version, char *format, char sep, char *name) {
@@ -179,9 +181,10 @@ void print_help(void) {
void
print_header_flag_interactive(char *in_tag, Header header)
{
- if (!strncmp(in_tag, "provides", 8)) print_list(header, RPMTAG_PROVIDENAME, "%2$s", 0, "");
+ if (!strncmp(in_tag, "provides", 8)) print_list_flags(header, RPMTAG_PROVIDENAME, RPMTAG_PROVIDEFLAGS,
+ RPMTAG_PROVIDEVERSION, "%2$s", 0, "");
else if (!strncmp(in_tag, "requires", 8)) print_list_flags(header, RPMTAG_REQUIRENAME, RPMTAG_REQUIREFLAGS,
- RPMTAG_REQUIREVERSION,"%2$s", 0, "");
+ RPMTAG_REQUIREVERSION, "%2$s", 0, "");
else if (!strncmp(in_tag, "conflicts", 9)) print_list_flags(header, RPMTAG_CONFLICTNAME, RPMTAG_CONFLICTFLAGS,
RPMTAG_CONFLICTVERSION, "%2$s", 0, "");
else if (!strncmp(in_tag, "obsoletes", 9)) print_list_flags(header, RPMTAG_OBSOLETENAME, RPMTAG_OBSOLETEFLAGS,