[vlc-commits] isatty() requires <unistd.h>

Rémi Denis-Courmont git at videolan.org
Thu Nov 24 18:24:55 CET 2011


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Nov 24 19:23:42 2011 +0200| [fa0e429bad0fae81a69c1ba89d41908ca18c8632] | committer: Rémi Denis-Courmont

isatty() requires <unistd.h>

Reported-by: KO Myung-Hun <komh78 at gmail.com>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=fa0e429bad0fae81a69c1ba89d41908ca18c8632
---

 src/config/help.c |    1 +
 src/libvlc.c      |    3 +++
 2 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/src/config/help.c b/src/config/help.c
index e11ff8c..6ab1a2b 100644
--- a/src/config/help.c
+++ b/src/config/help.c
@@ -38,6 +38,7 @@ static void PauseConsole (void);
 #else
 # define ShowConsole() (void)0
 # define PauseConsole() (void)0
+# include <unistd.h>
 #endif
 
 static void Help (vlc_object_t *, const char *);
diff --git a/src/libvlc.c b/src/libvlc.c
index c26d7b9..ef517d4 100644
--- a/src/libvlc.c
+++ b/src/libvlc.c
@@ -52,6 +52,9 @@
 #ifdef HAVE_LOCALE_H
 #   include <locale.h>
 #endif
+#ifdef HAVE_UNISTD_H
+#   include <unistd.h> /* isatty() */
+#endif
 
 #ifdef HAVE_DBUS
 /* used for one-instance mode */



More information about the vlc-commits mailing list