From 3ad2f39c0fdb52363d4e059247639be40b5cd11d Mon Sep 17 00:00:00 2001 From: ewt Date: Tue, 16 Jul 1996 20:22:09 +0000 Subject: [PATCH] added message for verbose mode CVS patchset: 865 CVS date: 1996/07/16 20:22:09 --- lib/uninstall.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lib/uninstall.c b/lib/uninstall.c index b9bed9b..7a62d2d 100644 --- a/lib/uninstall.c +++ b/lib/uninstall.c @@ -178,7 +178,7 @@ int rpmRemovePackage(char * prefix, rpmdb db, unsigned int offset, int flags) { Header h; int i; int fileCount; - char * rmmess, * name; + char * rmmess, * name, * version, * release; char * fnbuffer = NULL; dbIndexSet matches; int fnbuffersize = 0; @@ -198,9 +198,11 @@ int rpmRemovePackage(char * prefix, rpmdb db, unsigned int offset, int flags) { return 1; } + getEntry(h, RPMTAG_NAME, &type, (void **) &name, &count); + getEntry(h, RPMTAG_VERSION, &type, (void **) &version, &count); + getEntry(h, RPMTAG_RELEASE, &type, (void **) &release, &count); /* when we run scripts, we pass an argument which is the number of versions of this package that will be installed when we are finished */ - getEntry(h, RPMTAG_NAME, &type, (void **) &name, &count); if (rpmdbFindPackage(db, name, &matches)) { error(RPMERR_DBCORRUPT, "cannot read packages named %s for uninstall", name); @@ -214,6 +216,9 @@ int rpmRemovePackage(char * prefix, rpmdb db, unsigned int offset, int flags) { rmmess = "would remove"; } else { rmmess = "removing"; + if (isVerbose()) { + printf("Removing %s-%s-%s\n", name, version, release); + } } message(MESS_DEBUG, "running preuninstall script (if any)\n"); -- 2.7.4