aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2006-10-24 15:56:02 +0000
committerThierry Vignaud <tv@mandriva.org>2006-10-24 15:56:02 +0000
commit0f3c71ef887ca2badd6bfd25e0b871a1eb019b7e (patch)
tree073f4dd7e9e5993bfe754c31e224dc805aa40ad1
parenteabb5d03bd705a7c8990306b63f53aabe1d01a53 (diff)
downloadrpmdrake-0f3c71ef887ca2badd6bfd25e0b871a1eb019b7e.tar
rpmdrake-0f3c71ef887ca2badd6bfd25e0b871a1eb019b7e.tar.gz
rpmdrake-0f3c71ef887ca2badd6bfd25e0b871a1eb019b7e.tar.bz2
rpmdrake-0f3c71ef887ca2badd6bfd25e0b871a1eb019b7e.tar.xz
rpmdrake-0f3c71ef887ca2badd6bfd25e0b871a1eb019b7e.zip
check if any sensitive mount point is mounted read-only (#12967)
-rwxr-xr-xrpmdrake5
1 files changed, 5 insertions, 0 deletions
diff --git a/rpmdrake b/rpmdrake
index 7ec9df66..f742d45d 100755
--- a/rpmdrake
+++ b/rpmdrake
@@ -1225,6 +1225,11 @@ or you already installed all of them."));
};
my $do_action = sub {
+ require urpm::sys;
+ if (!urpm::sys::check_fs_writable()) {
+ $urpm->{fatal}(1, N("Error: %s appears to be mounted read-only.", $urpm::sys::mountpoint));
+ return;
+ }
if (!int(grep { $pkgs->{$_}{selected} } keys %$pkgs)) {
interactive_msg_(N("You need to select some packages first."), N("You need to select some packages first."));
return;