mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-10-11 17:13:47 +02:00
Changed /etc/init.d/rivendell to systemctl
This commit is contained in:
@@ -46,8 +46,8 @@ bool alsa_daemon_start_needed=false;
|
|||||||
void StopDaemons()
|
void StopDaemons()
|
||||||
{
|
{
|
||||||
if(alsa_manage_daemons) {
|
if(alsa_manage_daemons) {
|
||||||
if(system("/etc/init.d/rivendell status")==0) {
|
if(system("systemctl --quiet is-active rivendell")==0) {
|
||||||
system("/etc/init.d/rivendell stop");
|
system("systemctl --quiet stop rivendell");
|
||||||
alsa_daemon_start_needed=true;
|
alsa_daemon_start_needed=true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -57,7 +57,7 @@ void StopDaemons()
|
|||||||
void StartDaemons()
|
void StartDaemons()
|
||||||
{
|
{
|
||||||
if(alsa_daemon_start_needed) {
|
if(alsa_daemon_start_needed) {
|
||||||
system("/etc/init.d/rivendell start");
|
system("systemctl --quiet start rivendell");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -148,7 +148,7 @@ MainWidget::MainWidget(QWidget *parent)
|
|||||||
tr("The \"--manage-daemons\" switch requires root permissions."));
|
tr("The \"--manage-daemons\" switch requires root permissions."));
|
||||||
exit(256);
|
exit(256);
|
||||||
}
|
}
|
||||||
if(system("/etc/init.d/rivendell status")==0) {
|
if(system("systemctl --quiet is-active rivendell")==0) {
|
||||||
int r=QMessageBox::warning(this,tr("RDAlsaConfig warning"),
|
int r=QMessageBox::warning(this,tr("RDAlsaConfig warning"),
|
||||||
tr("Rivendell audio will be interrupted while running this program.\nContinue?"),
|
tr("Rivendell audio will be interrupted while running this program.\nContinue?"),
|
||||||
QMessageBox::Yes,QMessageBox::No);
|
QMessageBox::Yes,QMessageBox::No);
|
||||||
|
Reference in New Issue
Block a user