diff options
author | Mans Rullgard <mans@mansr.com> | 2012-06-21 16:33:36 +0100 |
---|---|---|
committer | Mans Rullgard <mans@mansr.com> | 2012-06-21 22:53:35 +0100 |
commit | 539df61193f2452ddeb74999f0ae301d7a7318cc (patch) | |
tree | 2116cd937e6229a379e817b17d1f1e5918f0e856 | |
parent | c19e0ebe532360aee043b5fb275257dc008968c3 (diff) | |
download | ffmpeg-streaming-539df61193f2452ddeb74999f0ae301d7a7318cc.zip ffmpeg-streaming-539df61193f2452ddeb74999f0ae301d7a7318cc.tar.gz |
log: include unistd.h only when needed
The only symbol this file uses from unistd.h is isatty(). By
including the header only when this function is used, the file
can be built on systems without unistd.h (which presumably also
lack isatty).
Signed-off-by: Mans Rullgard <mans@mansr.com>
-rw-r--r-- | libavutil/log.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavutil/log.c b/libavutil/log.c index 5e84129..e4a9fec 100644 --- a/libavutil/log.c +++ b/libavutil/log.c @@ -24,7 +24,11 @@ * logging functions */ +#include "config.h" + +#if HAVE_ISATTY #include <unistd.h> +#endif #include <stdlib.h> #include "avstring.h" #include "avutil.h" |