View | Details | Raw Unified | Return to bug 232184
Collapse All | Expand All

(-)files/patch-libs_libmythtv_recorders_ExternalStreamHandler.cpp (+40 lines)
Line 0 Link Here
1
2
--- libs/libmythtv/recorders/ExternalStreamHandler.cpp
3
+++ libs/libmythtv/recorders/ExternalStreamHandler.cpp
4
@@ -8,7 +8,7 @@
5
 #include <poll.h>
6
 #include <sys/ioctl.h>
7
 #endif
8
-#ifdef ANDROID
9
+#if defined(ANDROID) || defined(__FreeBSD__)
10
 #include <sys/wait.h>
11
 #endif
12
 
13
@@ -245,7 +245,7 @@ void ExternIO::Term(bool /*force*/)
14
 /* Return true if the process is not, or is no longer running */
15
 bool ExternIO::KillIfRunning(const QString & cmd)
16
 {
17
-#if CONFIG_DARWIN || (__FreeBSD__) || defined(__OpenBSD__)
18
+#if CONFIG_DARWIN || defined(__OpenBSD__)
19
     return false;
20
 #elif defined USING_MINGW
21
     return false;
22
@@ -253,8 +253,7 @@ bool ExternIO::KillIfRunning(const QString & cmd)
23
     return false;
24
 #else
25
     QString grp = QString("pgrep -x -f \"%1\" 2>&1 > /dev/null").arg(cmd);
26
-    QString kil = QString("pkill --signal 15 -x -f \"%1\" 2>&1 > /dev/null")
27
-                  .arg(cmd);
28
+    QString kil = QString("pkill -x -f \"%1\" 2>&1 > /dev/null").arg(cmd);
29
     int res_grp, res_kil;
30
 
31
     res_grp = system(grp.toUtf8().constData());
32
@@ -281,7 +280,7 @@ bool ExternIO::KillIfRunning(const QString & cmd)
33
 
34
     usleep(50000);
35
 
36
-    kil = QString("pkill --signal 9 -x -f \"%1\" 2>&1 > /dev/null").arg(cmd);
37
+    kil = QString("pkill -signal 9 -x -f \"%1\" 2>&1 > /dev/null").arg(cmd);
38
     res_kil = system(kil.toUtf8().constData());
39
     if (WEXITSTATUS(res_kil) > 0)
40
         LOG(VB_GENERAL, LOG_WARNING, QString("'%1' failed: %2")

Return to bug 232184