aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/Hal/Cdroms.pm13
1 files changed, 2 insertions, 11 deletions
diff --git a/lib/Hal/Cdroms.pm b/lib/Hal/Cdroms.pm
index 19d8263..a4e0b65 100644
--- a/lib/Hal/Cdroms.pm
+++ b/lib/Hal/Cdroms.pm
@@ -261,13 +261,13 @@ sub _reactor_wait {
if (my $val = $check_found->($msg)) {
$found_val = $val;
- _reactor_shutdown($reactor);
+ $reactor->shutdown;
}
1;
});
if ($timeout) {
$reactor->add_timeout($timeout, Net::DBus::Callback->new(method => sub {
- _reactor_shutdown($reactor);
+ $reactor->shutdown;
}));
}
$reactor->run;
@@ -275,15 +275,6 @@ sub _reactor_wait {
$found_val;
}
-sub _reactor_shutdown {
- my ($reactor) = @_;
-
- $reactor->shutdown;
-
- # ugly, but needed for shutdown to work...
- $reactor->add_timeout(1, Net::DBus::Callback->new(method => sub {}));
-}
-
sub member { my $e = shift; foreach (@_) { $e eq $_ and return 1 } 0 }
=head1 AUTHOR