From 271632f2a376ba30c086f40a0e31c8c418f4854b Mon Sep 17 00:00:00 2001 From: Kern Sibbald Date: Wed, 1 Nov 2017 09:40:34 +0100 Subject: [PATCH] Take a more conservative approach for setting killable true --- bacula/src/filed/job.c | 1 + bacula/src/stored/dircmd.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/bacula/src/filed/job.c b/bacula/src/filed/job.c index 305dfa7eb9..4d0cc0d348 100644 --- a/bacula/src/filed/job.c +++ b/bacula/src/filed/job.c @@ -282,6 +282,7 @@ static void *handle_director_request(BSOCK *dir) jcr->crypto.pki_recipients = me->pki_recipients; dir->set_jcr(jcr); + jcr->set_killable(true); /* allow dir to kill/cancel job */ /* Initialize SD start condition variable */ int errstat = pthread_cond_init(&jcr->job_start_wait, NULL); if (errstat != 0) { diff --git a/bacula/src/stored/dircmd.c b/bacula/src/stored/dircmd.c index 0519a141d9..dba2491b76 100644 --- a/bacula/src/stored/dircmd.c +++ b/bacula/src/stored/dircmd.c @@ -215,6 +215,8 @@ void *handle_connection_request(void *arg) dequeue_messages(jcr); /* dequeue any daemon messages */ + jcr->set_killable(true); /* allow dir to kill/cancel job */ + for (quit=false; !quit;) { /* Read command */ if ((bnet_stat = bs->recv()) <= 0) { -- 2.39.5