summaryrefslogtreecommitdiff
path: root/rpmqv.c
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2010-08-20 10:19:26 +0300
committerPanu Matilainen <pmatilai@redhat.com>2010-08-20 10:57:35 +0300
commita3795d0dc22a3ee482d7a8aec74ea108225cb3b6 (patch)
tree7c6cad826a39fa6b6e943d140aaec077a41d1ec6 /rpmqv.c
parent66ce5dc19c4662fb4e7870c5a55166435fbad083 (diff)
downloadlibrpm-tizen-a3795d0dc22a3ee482d7a8aec74ea108225cb3b6.tar.gz
librpm-tizen-a3795d0dc22a3ee482d7a8aec74ea108225cb3b6.tar.bz2
librpm-tizen-a3795d0dc22a3ee482d7a8aec74ea108225cb3b6.zip
Simplify --root argument checking
- We haven't accepted url's in as root since ages, wipe out the goo
Diffstat (limited to 'rpmqv.c')
-rw-r--r--rpmqv.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/rpmqv.c b/rpmqv.c
index 4032b9212..07f9d5b9b 100644
--- a/rpmqv.c
+++ b/rpmqv.c
@@ -424,16 +424,8 @@ int main(int argc, char *argv[])
"installation, erasure, querying, and "
"database rebuilds"));
- if (rpmcliRootDir) {
- switch (urlIsURL(rpmcliRootDir)) {
- default:
- if (bigMode & MODES_FOR_ROOT)
- break;
- case URL_IS_UNKNOWN:
- if (rpmcliRootDir[0] != '/')
- argerror(_("arguments to --root (-r) must begin with a /"));
- break;
- }
+ if (rpmcliRootDir && rpmcliRootDir[0] != '/') {
+ argerror(_("arguments to --root (-r) must begin with a /"));
}
if (quiet)