[FFmpeg-cvslog] file: Add S_ISFIFO compatability macro

Derek Buitenhuis git at videolan.org
Sun Sep 9 21:47:02 CEST 2012


ffmpeg | branch: master | Derek Buitenhuis <derek.buitenhuis at gmail.com> | Fri Sep  7 09:45:09 2012 -0400| [16c03f2e910a08a90118cc584c8b6a574eb96cd0] | committer: Michael Niedermayer

file: Add S_ISFIFO compatability macro

Not all systems have S_ISFIFO.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis at gmail.com>
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=16c03f2e910a08a90118cc584c8b6a574eb96cd0
---

 libavformat/file.c |    8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/libavformat/file.c b/libavformat/file.c
index 4e8129e..288275f 100644
--- a/libavformat/file.c
+++ b/libavformat/file.c
@@ -33,6 +33,14 @@
 #include "os_support.h"
 #include "url.h"
 
+/* Some systems may not have S_ISFIFO */
+#ifndef S_ISFIFO
+#  ifdef S_IFIFO
+#    define S_ISFIFO(m) (((m) & S_IFMT) == S_IFIFO)
+#  else
+#    define S_ISFIFO(m) 0
+#  endif
+#endif
 
 /* standard file protocol */
 



More information about the ffmpeg-cvslog mailing list