More reliable/gentle cancel (#412)

* Kill Borg with SIGINT instead SIGTERM
* Only send sigint to top-level process
This commit is contained in:
Manu 2020-05-22 16:16:20 +08:00 committed by GitHub
parent 426b849938
commit 361c5a1775
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -234,7 +234,7 @@ class BorgThread(QtCore.QThread, BackupProfileMixin):
def cancel(self):
if self.isRunning():
mutex.unlock()
os.killpg(os.getpgid(self.process.pid), signal.SIGTERM)
self.process.send_signal(signal.SIGINT)
self.terminate()
def process_result(self, result):