From 016206e42e864e761ea3c05c8f3c74d97bb9d2d9 Mon Sep 17 00:00:00 2001 From: jbj Date: Sat, 27 Dec 2003 01:50:30 +0000 Subject: Warn only if installing. CVS patchset: 7025 CVS date: 2003/12/27 01:50:30 --- lib/fsm.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/lib/fsm.c b/lib/fsm.c index e1358b0a7..cbafbd7ff 100644 --- a/lib/fsm.c +++ b/lib/fsm.c @@ -761,15 +761,18 @@ int fsmMapAttrs(FSM_t fsm) gid_t gid = fi->gid; if (fi->fuser && unameToUid(fi->fuser[i], &uid)) { - rpmMessage(RPMMESS_WARNING, - _("user %s does not exist - using root\n"), fi->fuser[i]); + if (fsm->goal == FSM_PKGINSTALL) + rpmMessage(RPMMESS_WARNING, + _("user %s does not exist - using root\n"), fi->fuser[i]); uid = 0; finalMode &= ~S_ISUID; /* turn off suid bit */ } if (fi->fgroup && gnameToGid(fi->fgroup[i], &gid)) { - rpmMessage(RPMMESS_WARNING, - _("group %s does not exist - using root\n"), fi->fgroup[i]); + if (fsm->goal == FSM_PKGINSTALL) + rpmMessage(RPMMESS_WARNING, + _("group %s does not exist - using root\n"), fi->fgroup[i]); + gid = 0; finalMode &= ~S_ISGID; /* turn off sgid bit */ } -- cgit v1.2.3