summaryrefslogtreecommitdiffstats
path: root/perl-install/printer/printerdrake.pm
diff options
context:
space:
mode:
authorTill Kamppeter <tkamppeter@mandriva.com>2005-02-08 14:41:46 +0000
committerTill Kamppeter <tkamppeter@mandriva.com>2005-02-08 14:41:46 +0000
commit8c30c712a136069a6450e447f191daa229aacf84 (patch)
tree1a5fe904269c3bac787dbfbe3ab8bb9cfb06a70d /perl-install/printer/printerdrake.pm
parent29c3201c8dc00e3384afc32ae946a59992498fbe (diff)
downloaddrakx-8c30c712a136069a6450e447f191daa229aacf84.tar
drakx-8c30c712a136069a6450e447f191daa229aacf84.tar.gz
drakx-8c30c712a136069a6450e447f191daa229aacf84.tar.bz2
drakx-8c30c712a136069a6450e447f191daa229aacf84.tar.xz
drakx-8c30c712a136069a6450e447f191daa229aacf84.zip
- Prevented restarting of HPOJ and reloading the parallel port kernel modules
when printerdrake's queue generator is called by the hotplug script.
Diffstat (limited to 'perl-install/printer/printerdrake.pm')
-rw-r--r--perl-install/printer/printerdrake.pm9
1 files changed, 6 insertions, 3 deletions
diff --git a/perl-install/printer/printerdrake.pm b/perl-install/printer/printerdrake.pm
index febb8b5e1..2e38748ed 100644
--- a/perl-install/printer/printerdrake.pm
+++ b/perl-install/printer/printerdrake.pm
@@ -743,16 +743,19 @@ sub configure_new_printers {
# When HPOJ is running, it blocks the printer ports on which it is
# configured, so we stop it here. If it is not installed or not
- # configured, this command has no effect.
+ # configured, this command has no effect. We do not stop HPOJ if we are
+ # called by the hotplug script, as HPOJ reloads the parallel port
+ # kernel modules and causes a new hotplug signal which leads to
+ # recursive calls of the hotplug script.
require services;
- services::stop("hpoj");
+ services::stop("hpoj") if !$::noX;
# Auto-detect local printers
my @autodetected = printer::detect::local_detect();
# We are ready with auto-detection, so we restart HPOJ here. If it
# is not installed or not configured, this command has no effect.
- services::start("hpoj");
+ services::start("hpoj") if !$::noX;
# No printer found? So no need of new queues.
return 1 if !@autodetected;