summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2012-04-25 16:38:19 +0000
committerThierry Vignaud <tv@mageia.org>2012-04-25 16:38:19 +0000
commit48960073093f0e6629e644e6bb31848eeaaf0860 (patch)
tree2338b0c4310bdf5ea2067abb6124728c9945fd59 /lib
parentc9cf94494c8c53b81656ee8bcdf91cd7a9b538dc (diff)
downloaddrakx-net-48960073093f0e6629e644e6bb31848eeaaf0860.tar
drakx-net-48960073093f0e6629e644e6bb31848eeaaf0860.tar.gz
drakx-net-48960073093f0e6629e644e6bb31848eeaaf0860.tar.bz2
drakx-net-48960073093f0e6629e644e6bb31848eeaaf0860.tar.xz
drakx-net-48960073093f0e6629e644e6bb31848eeaaf0860.zip
(ask_driver) do not try to access the full chroot path when running in chroot (mga#56052)
still need to look at #26046 and #44416
Diffstat (limited to 'lib')
-rw-r--r--lib/network/ndiswrapper.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/network/ndiswrapper.pm b/lib/network/ndiswrapper.pm
index d626770..136f206 100644
--- a/lib/network/ndiswrapper.pm
+++ b/lib/network/ndiswrapper.pm
@@ -41,7 +41,9 @@ sub ask_driver {
require run_program;
-d $::prefix . "$ndiswrapper_root/$driver" and run_program::rooted($::prefix, 'ndiswrapper', '-e', $driver);
- unless (run_program::rooted($::prefix, 'ndiswrapper', '-i', $inf_file)) {
+ my $rooted_path = $inf_file;
+ $rooted_path =~ s!^$::prefix!!;
+ unless (run_program::rooted($::prefix, 'ndiswrapper', '-i', $rooted_path)) {
$in->ask_warn(N("Error"), N("Unable to install the %s ndiswrapper driver!", $driver));
return undef;
}