From 0890dd25777c65562991248375c8513a8a70ec1e Mon Sep 17 00:00:00 2001 From: Marius Gavrilescu Date: Thu, 30 Jan 2014 18:27:55 +0200 Subject: [PATCH] Add contest support to gensrc --- lib/Gruntmaster/Daemon.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Gruntmaster/Daemon.pm b/lib/Gruntmaster/Daemon.pm index d636965..c3ee591 100644 --- a/lib/Gruntmaster/Daemon.pm +++ b/lib/Gruntmaster/Daemon.pm @@ -130,7 +130,7 @@ sub process{ set_job_errors $job, $errors; my $log = $Gruntmaster::Data::contest ? "ct/$Gruntmaster::Data::contest/log" : 'log'; - PUBLISH gensrc => $job; + PUBLISH gensrc => "$Gruntmaster::Data::contest.$job"; PUBLISH genpage => "$log/job/$job.html"; PUBLISH genpage => "$log/index.html"; PUBLISH genpage => "$log/st.html"; @@ -143,7 +143,7 @@ sub process{ sub got_job{ $_[0] =~ /^(\w*)\.(\d+)$/; my $job = $2; - $Gruntmaster::Data::contest = $1 if $1; + local $Gruntmaster::Data::contest = $1 if $1; get_logger->debug("Taking job $job@{[defined $1 ? \" of contest $1\" : '']}..."); if (set_job_daemon $job, hostname . ":$$") { get_logger->debug("Succesfully taken job $job"); -- 2.39.2