[xiph-commits] r14219 - icecast/trunk/icecast/src

karl at svn.xiph.org karl at svn.xiph.org
Thu Nov 22 19:17:40 PST 2007


Author: karl
Date: 2007-11-22 19:17:39 -0800 (Thu, 22 Nov 2007)
New Revision: 14219

Modified:
   icecast/trunk/icecast/src/compat.h
   icecast/trunk/icecast/src/connection.c
   icecast/trunk/icecast/src/main.c
   icecast/trunk/icecast/src/slave.c
Log:
minor header cleanup


Modified: icecast/trunk/icecast/src/compat.h
===================================================================
--- icecast/trunk/icecast/src/compat.h	2007-11-23 02:48:37 UTC (rev 14218)
+++ icecast/trunk/icecast/src/compat.h	2007-11-23 03:17:39 UTC (rev 14219)
@@ -20,12 +20,20 @@
  * Solaris.
  */
 
-#ifdef _WIN32
-#include <windows.h>
-#else
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
 #endif
 
+#ifdef TIME_WITH_SYS_TIME
+#  include <sys/time.h>
+#  include <time.h>
+#else
+#  ifdef HAVE_SYS_TIME_H
+#    include <sys/time.h>
+#  else
+#    include <time.h>
+#  endif
+#endif
 
 /* Make sure we define 64 bit types */
 #ifdef _WIN32

Modified: icecast/trunk/icecast/src/connection.c
===================================================================
--- icecast/trunk/icecast/src/connection.c	2007-11-23 02:48:37 UTC (rev 14218)
+++ icecast/trunk/icecast/src/connection.c	2007-11-23 03:17:39 UTC (rev 14219)
@@ -19,7 +19,6 @@
 #include <stdlib.h>
 #include <errno.h>
 #include <string.h>
-#include <time.h>
 #ifdef HAVE_POLL
 #include <sys/poll.h>
 #endif
@@ -27,7 +26,6 @@
 #include <sys/stat.h>
 
 #ifndef _WIN32
-#include <sys/time.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
 #else

Modified: icecast/trunk/icecast/src/main.c
===================================================================
--- icecast/trunk/icecast/src/main.c	2007-11-23 02:48:37 UTC (rev 14218)
+++ icecast/trunk/icecast/src/main.c	2007-11-23 03:17:39 UTC (rev 14219)
@@ -56,6 +56,7 @@
 #ifdef _WIN32
 /* For getpid() */
 #include <process.h>
+#include <windows.h>
 #define snprintf _snprintf
 #define getpid _getpid
 #endif

Modified: icecast/trunk/icecast/src/slave.c
===================================================================
--- icecast/trunk/icecast/src/slave.c	2007-11-23 02:48:37 UTC (rev 14218)
+++ icecast/trunk/icecast/src/slave.c	2007-11-23 03:17:39 UTC (rev 14219)
@@ -25,11 +25,9 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
-#include <time.h>
 #include <sys/types.h>
 
 #ifndef _WIN32
-#include <sys/time.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
 #else



More information about the commits mailing list