From e6ce60e6302ca2b70794c636080fb2d032c720b8 Mon Sep 17 00:00:00 2001 From: Philipp Schafft Date: Fri, 31 Oct 2014 09:00:45 +0000 Subject: [PATCH] rename ICE_LISTEN_QUEUE, ICE_RUNNING and ICE_HALTING so they have a prefix of ICECAST_ svn path=/icecast/trunk/icecast/; revision=19258 --- src/connection.c | 4 ++-- src/global.h | 6 +++--- src/main.c | 4 ++-- src/sighandler.c | 2 +- src/source.c | 6 +++--- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/connection.c b/src/connection.c index 6132529a..25c614d5 100644 --- a/src/connection.c +++ b/src/connection.c @@ -713,7 +713,7 @@ void connection_accept_loop (void) get_ssl_certificate (config); config_release_config (); - while (global.running == ICE_RUNNING) + while (global.running == ICECAST_RUNNING) { con = _accept_connection (duration); @@ -1434,7 +1434,7 @@ int connection_setup_sockets (ice_config_t *config) sock_t sock = sock_get_server_socket (listener->port, listener->bind_address); if (sock == SOCK_ERROR) break; - if (sock_listen (sock, ICE_LISTEN_QUEUE) == SOCK_ERROR) + if (sock_listen (sock, ICECAST_LISTEN_QUEUE) == SOCK_ERROR) { sock_close (sock); break; diff --git a/src/global.h b/src/global.h index 49bc2095..1770bc6b 100644 --- a/src/global.h +++ b/src/global.h @@ -13,10 +13,10 @@ #ifndef __GLOBAL_H__ #define __GLOBAL_H__ -#define ICE_LISTEN_QUEUE 5 +#define ICECAST_LISTEN_QUEUE 5 -#define ICE_RUNNING 1 -#define ICE_HALTING 2 +#define ICECAST_RUNNING 1 +#define ICECAST_HALTING 2 #define ICECAST_VERSION_STRING "Icecast " PACKAGE_VERSION diff --git a/src/main.c b/src/main.c index 2dfcd54a..9a80bb69 100644 --- a/src/main.c +++ b/src/main.c @@ -286,7 +286,7 @@ static int _start_listening(void) { int i; for(i=0; i < global.server_sockets; i++) { - if (sock_listen(global.serversock[i], ICE_LISTEN_QUEUE) == SOCK_ERROR) + if (sock_listen(global.serversock[i], ICECAST_LISTEN_QUEUE) == SOCK_ERROR) return 0; sock_set_blocking(global.serversock[i], 0); @@ -511,7 +511,7 @@ int main(int argc, char **argv) /* REM 3D Graphics */ /* let her rip */ - global.running = ICE_RUNNING; + global.running = ICECAST_RUNNING; /* Startup yp thread */ yp_initialize(); diff --git a/src/sighandler.c b/src/sighandler.c index f53bd742..86f310d0 100644 --- a/src/sighandler.c +++ b/src/sighandler.c @@ -70,7 +70,7 @@ void _sig_die(int signo) ICECAST_LOG_INFO("Caught signal %d, shutting down...", signo); /* inform the server to start shutting down */ - global.running = ICE_HALTING; + global.running = ICECAST_HALTING; } #endif diff --git a/src/source.c b/src/source.c index 83646d32..7d07ea22 100644 --- a/src/source.c +++ b/src/source.c @@ -462,7 +462,7 @@ static refbuf_t *get_next_buffer (source_t *source) if (source->short_delay) delay = 0; - while (global.running == ICE_RUNNING && source->running) + while (global.running == ICECAST_RUNNING && source->running) { int fds = 0; time_t current = time (NULL); @@ -702,7 +702,7 @@ void source_main (source_t *source) source_init (source); - while (global.running == ICE_RUNNING && source->running) { + while (global.running == ICECAST_RUNNING && source->running) { int remove_from_q; refbuf = get_next_buffer (source); @@ -1455,7 +1455,7 @@ void source_recheck_mounts (int update_all) stats_event (mount->mountname, NULL, NULL); /* check for fallback to file */ - if (global.running == ICE_RUNNING && mount->fallback_mount) + if (global.running == ICECAST_RUNNING && mount->fallback_mount) { source_t *fallback = source_find_mount (mount->fallback_mount); if (fallback == NULL)