From a63db013c53a49a6654a55a99f83a36d81b74d27 Mon Sep 17 00:00:00 2001 From: Olivier Blin Date: Tue, 3 Mar 2009 18:17:12 +0000 Subject: fix crash in net_applet when mandi is started (happens if mandi was not available at net_applet start), this requires some API change to split init code, so that we do not add the dbus filters every time we try to reconnect the network::ifw object --- lib/network/ifw.pm | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'lib/network/ifw.pm') diff --git a/lib/network/ifw.pm b/lib/network/ifw.pm index e418d92..1c7996d 100644 --- a/lib/network/ifw.pm +++ b/lib/network/ifw.pm @@ -5,13 +5,15 @@ use common; our @ISA = qw(dbus_object); -sub new { - my ($type, $bus, $filter) = @_; - +sub init { + my ($bus, $filter) = @_; my $con = $bus->{connection}; $con->add_filter($filter); $con->add_match("type='signal',interface='com.mandriva.monitoring.ifw'"); +} +sub new { + my ($type, $bus) = @_; require dbus_object; my $o = dbus_object::new($type, $bus, -- cgit v1.2.1