be a bit more carefull about checking --rcfiles argument

CVS patchset: 1436
CVS date: 1997/02/17 20:28:50
This commit is contained in:
ewt 1997-02-17 20:28:50 +00:00
parent 14b83466f4
commit ef69473766
1 changed files with 5 additions and 4 deletions

9
rpm.c
View File

@ -507,11 +507,11 @@ int main(int argc, char ** argv) {
currarg = argv;
while (*currarg) {
if (!strcmp(*currarg, "--rcfile")) {
rcfile = *(currarg + 1);
rcfile = *(++currarg);
} else if (!strcmp(*currarg, "--buildarch")) {
arch = *(currarg + 1);
arch = *(++currarg);
} else if (!strcmp(*currarg, "--buildos")) {
os = *(currarg + 1);
os = *(++currarg);
} else if (!strcmp(*currarg, "--showrc")) {
showrc = 1;
building = 1;
@ -521,7 +521,8 @@ int main(int argc, char ** argv) {
!strcmp(*currarg, "--recompile")) {
building = 1;
}
currarg++;
if (*currarg) currarg++;
}
/* reading this early makes it easy to override */