From da0307292fe72d9db64c97831f602d011c3e4971 Mon Sep 17 00:00:00 2001 From: rettenbe Date: Mon, 3 Mar 2008 14:37:30 +0000 Subject: [PATCH] bugfix: better infos in daemon_log in error case git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9250 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-si/modules/GosaPackages.pm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gosa-si/modules/GosaPackages.pm b/gosa-si/modules/GosaPackages.pm index b4b37bb9b..b3925310e 100644 --- a/gosa-si/modules/GosaPackages.pm +++ b/gosa-si/modules/GosaPackages.pm @@ -303,14 +303,14 @@ sub process_incoming_msg { sub process_gosa_msg { my ($msg, $msg_hash, $session_id) = @_ ; my $out_msg; - my @out_msg_l = (); + my @out_msg_l = ('nohandler'); my $header = @{$msg_hash->{'header'}}[0]; $header =~ s/gosa_//; if( exists $event_hash->{$header} ) { # a event exists with the header as name - &main::daemon_log("found event '$header' at event-module '".$event_hash->{$header}."'", 5); + &main::daemon_log("INFO: found event '$header' at event-module '".$event_hash->{$header}."'", 5); no strict 'refs'; @out_msg_l = &{$event_hash->{$header}."::$header"}($msg, $msg_hash, $session_id); } @@ -318,8 +318,9 @@ sub process_gosa_msg { # if delivery not possible raise error and return if( not @out_msg_l ) { &main::daemon_log("WARNING: GosaPackages got no answer from event handler '$header'", 3); - } elsif( 0 == @out_msg_l) { + } elsif( $out_msg_l[0] eq 'nohandler') { &main::daemon_log("ERROR: GosaPackages: no event handler or core function defined for '$header'", 1); + @out_msg_l = (); } return @out_msg_l; -- 2.30.2