From 739d544c346d83b2ff9f100f4fa45d9585cda525 Mon Sep 17 00:00:00 2001 From: Michael Smith Date: Sat, 17 Dec 2005 12:41:34 +0000 Subject: [PATCH] Having both os.h and compat.h to do similar things is pointless; remove os.h svn path=/icecast/trunk/icecast/; revision=10620 --- src/Makefile.am | 2 +- src/admin.c | 2 +- src/compat.h | 11 +++++++++++ src/connection.c | 2 +- src/logging.c | 2 +- src/main.c | 2 +- src/os.h | 30 ------------------------------ src/slave.c | 2 +- src/source.c | 2 +- src/util.c | 2 +- 10 files changed, 19 insertions(+), 38 deletions(-) delete mode 100644 src/os.h diff --git a/src/Makefile.am b/src/Makefile.am index 1b41e1a6..8db2e5c3 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -6,7 +6,7 @@ SUBDIRS = avl thread httpp net log timing bin_PROGRAMS = icecast -noinst_HEADERS = admin.h cfgfile.h os.h logging.h sighandler.h connection.h \ +noinst_HEADERS = admin.h cfgfile.h logging.h sighandler.h connection.h \ global.h util.h slave.h source.h stats.h refbuf.h client.h \ compat.h fserve.h xslt.h yp.h event.h md5.h \ auth.h auth_htpasswd.h auth_url.h \ diff --git a/src/admin.c b/src/admin.c index 3db88c21..4adc582a 100644 --- a/src/admin.c +++ b/src/admin.c @@ -30,7 +30,7 @@ #include "global.h" #include "event.h" #include "stats.h" -#include "os.h" +#include "compat.h" #include "xslt.h" #include "fserve.h" diff --git a/src/compat.h b/src/compat.h index 6cfb6450..50691f49 100644 --- a/src/compat.h +++ b/src/compat.h @@ -20,12 +20,23 @@ * Solaris. */ +#ifdef _WIN32 +#include +#else +#include +#endif + + /* Make sure we define 64 bit types */ #ifdef _WIN32 +# define PATH_SEPARATOR "\\" +# define size_t unsigned int +# define ssize_t int # define int64_t __int64 # define uint64_t unsigned __int64 # define uint32_t unsigned int #else +# define PATH_SEPARATOR "/" # if defined(HAVE_STDINT_H) # include # elif defined(HAVE_INTTYPES_H) diff --git a/src/connection.c b/src/connection.c index f5924ffd..290673b3 100644 --- a/src/connection.c +++ b/src/connection.c @@ -34,7 +34,7 @@ #define strncasecmp strnicmp #endif -#include "os.h" +#include "compat.h" #include "thread/thread.h" #include "avl/avl.h" diff --git a/src/logging.c b/src/logging.c index 786e76cb..ed883e5d 100644 --- a/src/logging.c +++ b/src/logging.c @@ -25,7 +25,7 @@ #include "refbuf.h" #include "client.h" -#include "os.h" +#include "compat.h" #include "cfgfile.h" #include "logging.h" #include "util.h" diff --git a/src/main.c b/src/main.c index 25328ab1..86137e23 100644 --- a/src/main.c +++ b/src/main.c @@ -39,7 +39,7 @@ #include "sighandler.h" #include "global.h" -#include "os.h" +#include "compat.h" #include "connection.h" #include "refbuf.h" #include "client.h" diff --git a/src/os.h b/src/os.h deleted file mode 100644 index d74d88d0..00000000 --- a/src/os.h +++ /dev/null @@ -1,30 +0,0 @@ -/* Icecast - * - * This program is distributed under the GNU General Public License, version 2. - * A copy of this license is included with this source. - * - * Copyright 2000-2004, Jack Moffitt , - * oddsock , - * Karl Heyes - * and others (see AUTHORS for details). - */ - -#ifndef __OS_H__ -#define __OS_H__ - -#ifdef _WIN32 -#include -#else -#include -#endif - -#ifdef _WIN32 -#define PATH_SEPARATOR "\\" -#define size_t unsigned int -#define ssize_t int -#else -#define PATH_SEPARATOR "/" -#endif - -#endif /* __OS_H__ */ diff --git a/src/slave.c b/src/slave.c index ece0859d..de1f8eb6 100644 --- a/src/slave.c +++ b/src/slave.c @@ -39,7 +39,7 @@ #define strncasecmp strnicmp #endif -#include "os.h" +#include "compat.h" #include "thread/thread.h" #include "avl/avl.h" diff --git a/src/source.c b/src/source.c index 7be2f6dd..0be562a2 100644 --- a/src/source.c +++ b/src/source.c @@ -50,7 +50,7 @@ #include "format.h" #include "fserve.h" #include "auth.h" -#include "os.h" +#include "compat.h" #undef CATMODULE #define CATMODULE "source" diff --git a/src/util.c b/src/util.c index aa922ef3..3aa14730 100644 --- a/src/util.c +++ b/src/util.c @@ -40,7 +40,7 @@ #include "cfgfile.h" #include "util.h" -#include "os.h" +#include "compat.h" #include "refbuf.h" #include "connection.h" #include "client.h"