mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-10-30 09:13:51 +01:00
2021-08-08 Fred Gleason <fredg@paravelsystems.com>
* Fixed a bug in rdservice(8) that could cause a segfault when restarting dropboxes. Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
@@ -22190,3 +22190,6 @@
|
||||
* Fixed a regression in rdadmin(1) that caused the 'Norm. Level'
|
||||
and 'Autotrim Level' columns to display incorrect values in the
|
||||
'Dropbox Configuration' dialog.
|
||||
2021-08-08 Fred Gleason <fredg@paravelsystems.com>
|
||||
* Fixed a bug in rdservice(8) that could cause a segfault when
|
||||
restarting dropboxes.
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
//
|
||||
// Shutdown routines for the Rivendell Services Manager
|
||||
//
|
||||
// (C) Copyright 2018 Fred Gleason <fredg@paravelsystems.com>
|
||||
// (C) Copyright 2018-2021 Fred Gleason <fredg@paravelsystems.com>
|
||||
//
|
||||
// This program is free software; you can redistribute it and/or modify
|
||||
// it under the terms of the GNU General Public License version 2 as
|
||||
@@ -42,13 +42,18 @@ void MainObject::Shutdown()
|
||||
|
||||
void MainObject::ShutdownDropboxes()
|
||||
{
|
||||
QList<int> kill_ids;
|
||||
|
||||
for(QMap<int,RDProcess *>::iterator it=svc_processes.begin();
|
||||
it!=svc_processes.end();it++) {
|
||||
if(it.key()>=RDSERVICE_FIRST_DROPBOX_ID) {
|
||||
it.value()->process()->kill();
|
||||
it.value()->process()->waitForFinished();
|
||||
delete it.value();
|
||||
svc_processes.erase(it);
|
||||
kill_ids.push_back(it.key());
|
||||
}
|
||||
}
|
||||
for(int i=0;i<kill_ids.size();i++) {
|
||||
svc_processes.value(kill_ids.at(i))->process()->kill();
|
||||
svc_processes.value(kill_ids.at(i))->process()->waitForFinished();
|
||||
delete svc_processes.value(kill_ids.at(i));
|
||||
svc_processes.remove(kill_ids.at(i));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user