[Telepathy-commits] [telepathy-glib/master] Conditionally include <unistd.h>, Windows doesn't have one

Simon McVittie simon.mcvittie at collabora.co.uk
Thu Jan 8 05:42:27 PST 2009


Patch from Sunil Mohan Adapa <sunil at synovel.com>
---
 telepathy-glib/debug.c |    3 +++
 telepathy-glib/run.c   |    3 +++
 2 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/telepathy-glib/debug.c b/telepathy-glib/debug.c
index a452afc..cbd1d6a 100644
--- a/telepathy-glib/debug.c
+++ b/telepathy-glib/debug.c
@@ -57,7 +57,10 @@
 #include <fcntl.h>
 #include <stdarg.h>
 #include <sys/stat.h>
+
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
+#endif
 
 #include <glib.h>
 #include <glib/gstdio.h>
diff --git a/telepathy-glib/run.c b/telepathy-glib/run.c
index 888519e..3b59c56 100644
--- a/telepathy-glib/run.c
+++ b/telepathy-glib/run.c
@@ -40,7 +40,10 @@
 #include <dbus/dbus-glib-lowlevel.h>
 #include <stdlib.h>
 #include <string.h>
+
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
+#endif
 
 #include "debug-internal.h"
 #include <telepathy-glib/base-connection-manager.h>
-- 
1.5.6.5




More information about the Telepathy-commits mailing list