summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS2
-rwxr-xr-xurpmi6
2 files changed, 5 insertions, 3 deletions
diff --git a/NEWS b/NEWS
index 93e2129e..daed9d71 100644
--- a/NEWS
+++ b/NEWS
@@ -1,4 +1,6 @@
- urpmi:
+ o return the proper error code in some cases when failing to install some
+ packages
o --test: do not display "More information on package"
o --test: do not update /var/lib/rpm/installed-through-deps.list
diff --git a/urpmi b/urpmi
index 7c6aa045..0b811995 100755
--- a/urpmi
+++ b/urpmi
@@ -553,7 +553,7 @@ has to be removed for others to be upgraded:\n%s\n", $list)
have to be removed for others to be upgraded:\n%s\n", $list);
print "$msg\n";
dudf_invoke($dudf, "dudf_exit", 0, $msg);
- exit 0;
+ exit 17;
}
my $msg = urpm::select::conflicting_packages_msg_(\@conflicting_pkgs_msgs);
@@ -563,7 +563,7 @@ have to be removed for others to be upgraded:\n%s\n", $list);
if ($urpm->{options}{auto}) {
print "$msg\n";
} else {
- $force || urpm::msg::ask_yes_or_no($msg) or exit 0;
+ $force || urpm::msg::ask_yes_or_no($msg) or exit 17;
}
}
@@ -633,7 +633,7 @@ if (!$urpm->{options}{auto} && $ask_user && $urpm->{nb_install} || $env && !$opt
exit 0; #- exit now for specific environment.
}
my $noexpr = N("Nn");
- $force || message_input_($p . N(" (Y/n) "), boolean => 1) !~ /[$noexpr]/ or exit 0;
+ $force || message_input_($p . N(" (Y/n) "), boolean => 1) !~ /[$noexpr]/ or exit 17;
}
dudf_invoke($dudf, "check_removed_upgraded", $state);