Bug 33108 - rpm --querytags barfs if any other options given
rpm --querytags barfs if any other options given
Product: Red Hat Linux
Classification: Retired
Component: rpm (Show other bugs)
i386 Linux
medium Severity low
: ---
: ---
Assigned To: Jeff Johnson
David Lawrence
Depends On:
  Show dependency treegraph
Reported: 2001-03-25 00:33 EST by j. alan eldridge
Modified: 2007-04-18 12:32 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-03-25 00:33:28 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description j. alan eldridge 2001-03-25 00:33:24 EST
This is an inconsistency more than anything else, brought to my attention
because I use a wrapper around rpm to clean out LD_* vars and to set a
local rc file, if present.

That is, I do:
[[ $(id -u) != 0 ]] && {
    [ -f ~/.rpmrc ] && rcfile="--rcfile ~/.rpmrc"
exec $rpm $rcfile ${1+"$@"}

I the case whre I have the local rc file,  "~/bin/rpm --querytags" results
	/bin/rpm --rcfile ~/.rpmrc --querytags
which I will maintain is *completely* benign, harmless, wouldn't hurt a
kitten, etc, etc.

However, /bin/rpm itself doesn't like it, complaining "rpm: unexpected
arguments to --querytags".  [strace shows that the popt expansion of
--querytags never happens; the error is spat out before an attempt to exec
"/usr/lib/rpm/rpmq --querytag" happens.]

although i have not exhaustively tested, this looks from the man page to be
the *only* option that rpm treats as "this one, and not anything else, or
you'll be sorry". i can't see the harm in relaxing the checking a bit; an
rcfile argument should be allowed pretty much anywhere, i would think.
Comment 1 Jeff Johnson 2001-03-26 08:45:22 EST
Yup. Workaround by giving --querytags w/o other options.

Note You need to log in before you can comment on or make changes to this bug.