[gtk] gdk/gdkprofiler.c: Don't include unistd.h unconditionally



commit 705bf48eedabd317d9743e8afbc0496f8654f27a
Author: Chun-wei Fan <fanchunwei src gnome org>
Date:   Tue May 7 17:55:03 2019 -0700

    gdk/gdkprofiler.c: Don't include unistd.h unconditionally
    
    unistd.h is not universally available, so only include it when it can be
    found during the configure stage.

 gdk/gdkprofiler.c | 3 +++
 1 file changed, 3 insertions(+)
---
diff --git a/gdk/gdkprofiler.c b/gdk/gdkprofiler.c
index de04a3ce9f..aed2557de6 100644
--- a/gdk/gdkprofiler.c
+++ b/gdk/gdkprofiler.c
@@ -21,7 +21,10 @@
 #include "config.h"
 
 #include <sys/types.h>
+
+#ifdef HAVE_UNISTD_H
 #include <unistd.h>
+#endif
 
 #include "gdkversionmacros.h"
 #include "gdkprofiler.h"


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]