From ee4c8507fb1969a0f183ff57536d9eeb0a6d96d1 Mon Sep 17 00:00:00 2001 From: Alexey Bazhin Date: Tue, 10 Sep 2024 10:06:33 +0300 Subject: [PATCH] Fix preprocessor directives --- src/misc/hev-exec.c | 12 ++++++------ src/misc/hev-utils.c | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/misc/hev-exec.c b/src/misc/hev-exec.c index fbcf9b8..287b60f 100644 --- a/src/misc/hev-exec.c +++ b/src/misc/hev-exec.c @@ -22,7 +22,12 @@ #include "hev-exec.h" -#ifndef TARGET_OS_TV +#if TARGET_OS_TV +void +hev_exec_run (const char *script_path, const char *tun_name, int wait) +{ +} +#else static void signal_handler (int signum) { @@ -51,9 +56,4 @@ hev_exec_run (const char *script_path, const char *tun_name, int wait) LOG_E ("exec %s %s", script_path, tun_name); exit (-1); } -#else -void -hev_exec_run (const char *script_path, const char *tun_name, int wait) -{ -} #endif diff --git a/src/misc/hev-utils.c b/src/misc/hev-utils.c index 0355eaa..6c2316a 100644 --- a/src/misc/hev-utils.c +++ b/src/misc/hev-utils.c @@ -36,7 +36,7 @@ run_as_daemon (const char *pid_file) #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wdeprecated-declarations" -#ifndef TARGET_OS_TV +#if !(TARGET_OS_TV) if (daemon (0, 0)) { /* ignore return value */ }