#include <unistd.h>
#include "empio.h"
#include "empthread.h"
+#include "file.h"
#include "ioqueue.h"
#include "misc.h"
#include "queue.h"
int cc;
int res;
+ if (waitforinput)
+ ef_make_stale();
+
/* Not a read IOP */
if ((iop->flags & IO_READ) == 0) {
errno = EBADF;
int n;
int remain;
+ if (waitforoutput)
+ ef_make_stale();
+
/* If there is no output waiting. */
if (!io_outputwaiting(iop))
return 0;
{
int len;
+ if (doWait)
+ ef_make_stale();
+
if ((iop->flags & IO_WRITE) == 0)
return -1;
ioq_append(iop->output, buf, nbytes);
{
int n;
+ ef_make_stale();
+
/*
* Mustn't block a player thread while update is pending, or else
* a malicous player could delay the update indefinitely