aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2006-11-27 13:47:31 +0000
committerThierry Vignaud <tv@mandriva.org>2006-11-27 13:47:31 +0000
commit05de35021ed4af14e74c4e4297c3df0be9a1f299 (patch)
tree27541306c1ab46047af5d10d595bf6a3bdf94669
parentf683f5c9afec5b7f46704286b465bc4d837d9552 (diff)
downloadrpmdrake-05de35021ed4af14e74c4e4297c3df0be9a1f299.tar
rpmdrake-05de35021ed4af14e74c4e4297c3df0be9a1f299.tar.gz
rpmdrake-05de35021ed4af14e74c4e4297c3df0be9a1f299.tar.bz2
rpmdrake-05de35021ed4af14e74c4e4297c3df0be9a1f299.tar.xz
rpmdrake-05de35021ed4af14e74c4e4297c3df0be9a1f299.zip
(get_pkgs) fix urpmi db locking by locking it only once we've a valid $urpm
-rwxr-xr-xrpmdrake3
1 files changed, 2 insertions, 1 deletions
diff --git a/rpmdrake b/rpmdrake
index 381d1bd2..4bf591ef 100755
--- a/rpmdrake
+++ b/rpmdrake
@@ -1496,7 +1496,6 @@ sub get_pkgs {
};
- my $_lock = urpm::lock::urpmi_db($urpm);
if (!$urpm) {
$urpm ||= urpm->new;
$urpm->{fatal} = $fatal_handler;
@@ -1507,6 +1506,8 @@ sub get_pkgs {
exec('edit-urpm-sources.pl');
}
}
+ my $_lock = urpm::lock::urpmi_db($urpm);
+ sleep(10000);
my $statedir = $urpm->{statedir};
@update_medias = grep { !$_->{ignore} && $_->{update} } @{$urpm->{media}};