From e0ba7b09d1e8e68c0e65bf462a28d1edd896f3e5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Jan=20Kr=C3=BCger?= Date: Fri, 5 Nov 2010 06:52:05 +0100 Subject: [PATCH] jobd: when running job callbacks, properly pass the job info structure MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Stopped working due to sloppy reworking of handler code in 0fdf2b89. This fixes it. Signed-off-by: Jan Krüger --- jobd/jobd.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jobd/jobd.pl b/jobd/jobd.pl index db42860..3c96a07 100755 --- a/jobd/jobd.pl +++ b/jobd/jobd.pl @@ -196,11 +196,11 @@ sub reap_finished_jobs { # XXX- we currently don't care } if (@child && !$child[0]->{'finished'}) { - $child[0]->{'on_success'}->($_) if defined($child[0]->{'on_success'}); + $child[0]->{'on_success'}->($child[0]) if defined($child[0]->{'on_success'}); $child[0]->{'finished'} = 1; $jobs_executed++; } elsif (@child) { - $child[0]->{'on_error'}->($_) if defined($child[0]->{'on_error'}); + $child[0]->{'on_error'}->($child[0]) if defined($child[0]->{'on_error'}); } } @running = grep { $_->{'finished'} == 0 } @running; -- 2.11.4.GIT