]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
use tvheadend_is_running() instead direct tvheadend_running variable
authorJaroslav Kysela <perex@perex.cz>
Wed, 17 Jan 2018 17:00:41 +0000 (18:00 +0100)
committerJaroslav Kysela <perex@perex.cz>
Wed, 17 Jan 2018 17:00:41 +0000 (18:00 +0100)
src/dvr/dvr_inotify.c
src/fsmonitor.c
src/input/mpegts/linuxdvb/linuxdvb_ca.c
src/main.c

index 979fb02892871df944baa4074854d98b3be16c5d..17456d5a3c5c6ae55014999be6896c40944dee6f 100644 (file)
@@ -379,7 +379,7 @@ void* _dvr_inotify_thread ( void *p )
   int fromfd;
   int cookie;
 
-  while (atomic_get(&tvheadend_running)) {
+  while (tvheadend_is_running()) {
 
     /* Read events */
     fromfd = 0;
index f5a8ef7eb68256060497e7e4658058123c90a0ad..557c2c2fb3a67cde313d7fac1e3b68e66c7cff03 100644 (file)
@@ -53,7 +53,7 @@ fsmonitor_thread ( void* p )
   fsmonitor_link_t *fml;
   fsmonitor_t *fsm;
 
-  while (atomic_get(&tvheadend_running)) {
+  while (tvheadend_is_running()) {
 
     fd = atomic_get(&fsmonitor_fd);
     if (fd < 0)
index c70dba3a563d51384d8b6401a6ac60c381fe281d..c3e1ee2df8f2adb9ebcaab1919f7c140d960d434 100644 (file)
@@ -294,7 +294,7 @@ linuxdvb_ca_thread ( void *aux )
   poll = tvhpoll_create(evsize + 1);
   tm = mclk();
   waitms = 250;
-  while (tvheadend_running && !quit) {
+  while (tvheadend_is_running() && !quit) {
     evp = ev;
     evp->fd = linuxdvb_ca_pipe.rd;
     evp->events = TVHPOLL_IN;
index 84b8ea1b24010217c50ff331dc0717b983aa2675..9969034a92d38f8c136f179690517a7933c5666e 100644 (file)
@@ -140,7 +140,7 @@ static cmdline_opt_t* cmdline_opt_find
 /*
  * Globals
  */
-int              tvheadend_running;
+int              tvheadend_running; /* do not use directly: tvheadend_is_running() */
 int              tvheadend_webui_port;
 int              tvheadend_webui_debug;
 int              tvheadend_htsp_port;