From 16c03f2e910a08a90118cc584c8b6a574eb96cd0 Mon Sep 17 00:00:00 2001
From: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Date: Fri, 7 Sep 2012 09:45:09 -0400
Subject: [PATCH] file: Add S_ISFIFO compatability macro

Not all systems have S_ISFIFO.

Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
---
 libavformat/file.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/libavformat/file.c b/libavformat/file.c
index 4e8129e9ae..288275f6ef 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 */