From: Dylan William Hardison Date: Thu, 29 Mar 2018 19:54:54 +0000 (-0400) Subject: Bug 1450010 - The jobqueue supervisor's pidfile should not be stored in the data... X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f58deda411a1f9c260b293ecd58e37843c2debca;p=thirdparty%2Fbugzilla.git Bug 1450010 - The jobqueue supervisor's pidfile should not be stored in the data directory --- diff --git a/Bugzilla/JobQueue/Runner.pm b/Bugzilla/JobQueue/Runner.pm index 5cf7d82eb..0177de40a 100644 --- a/Bugzilla/JobQueue/Runner.pm +++ b/Bugzilla/JobQueue/Runner.pm @@ -26,7 +26,7 @@ use Cwd qw(abs_path); use English qw(-no_match_vars $PROGRAM_NAME $EXECUTABLE_NAME); use File::Basename; use File::Copy; -use File::Spec::Functions qw(catfile); +use File::Spec::Functions qw(catfile tmpdir); use Future; use Future::Utils qw(fmap_void); use IO::Async::Loop; @@ -52,7 +52,7 @@ sub gd_preconfig { my $pidfile = $self->{gd_args}{pidfile}; if ( !$pidfile ) { - $pidfile = bz_locations()->{datadir} . '/' . $self->{gd_progname} . '.pid'; + $pidfile = catfile(tmpdir(), $self->{gd_progname} . '.pid'); } return ( pidfile => $pidfile ); }