summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwtc%netscape.com <devnull@localhost>2000-01-08 16:36:59 +0000
committerwtc%netscape.com <devnull@localhost>2000-01-08 16:36:59 +0000
commite52c4005d0a5971bc2d8c30c046e47079cd8ac04 (patch)
treea49a914c8080a10d4296ffc914aa841cbe88d015
parente974aaee2dc9fb622c9c6702ceacf0bba636648b (diff)
downloadnspr-hg-e52c4005d0a5971bc2d8c30c046e47079cd8ac04.tar.gz
For platforms that don't implement PR_CreatePipe, define PipeAvailable
and PipeAvailable64 as simply returning -1. This way we don't need to define the _MD_PIPEAVAILABLE macro for those platforms.
-rw-r--r--pr/src/io/prfile.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/pr/src/io/prfile.c b/pr/src/io/prfile.c
index 7bc34e6a..31540e6a 100644
--- a/pr/src/io/prfile.c
+++ b/pr/src/io/prfile.c
@@ -155,6 +155,7 @@ static PRInt64 PR_CALLBACK FileAvailable64(PRFileDesc *fd)
return result;
}
+#if defined(XP_UNIX) || defined(WIN32)
static PRInt32 PR_CALLBACK PipeAvailable(PRFileDesc *fd)
{
PRInt32 rv;
@@ -168,6 +169,19 @@ static PRInt64 PR_CALLBACK PipeAvailable64(PRFileDesc *fd)
LL_I2L(rv, _PR_MD_PIPEAVAILABLE(fd));
return rv;
}
+#else
+static PRInt32 PR_CALLBACK PipeAvailable(PRFileDesc *fd)
+{
+ return -1;
+}
+
+static PRInt64 PR_CALLBACK PipeAvailable64(PRFileDesc *fd)
+{
+ PRInt64 rv;
+ LL_I2L(rv, -1);
+ return rv;
+}
+#endif
static PRStatus PR_CALLBACK PipeSync(PRFileDesc *fd)
{