Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/pacman/util.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/pacman/util.c b/src/pacman/util.c
index a279e004..af77e8ea 100644
--- a/src/pacman/util.c
+++ b/src/pacman/util.c
@@ -195,8 +195,10 @@ int yesno(char *fmt, ...)
char response[32];
va_list args;
- if(!config->noconfirm)
- {
+ if(config->noconfirm) {
+ return(1);
+ }
+
va_start(args, fmt);
vprintf(fmt, args);
va_end(args);
@@ -222,9 +224,6 @@ int yesno(char *fmt, ...)
}
}
return(0);
- } else {
- return(1);
- }
}
/* match a string against a regular expression */