added a dual direction pipe (rwpipe) to awk.

- will not work on WIN32 until qse_pcp_t is completed on the platform.
This commit is contained in:
2009-01-17 04:20:22 +00:00
parent 46e4ed5087
commit 07d8efa7c2
12 changed files with 204 additions and 115 deletions

View File

@ -351,14 +351,20 @@ static qse_ssize_t awk_extio_pipe (
if (epa->mode == QSE_AWK_EXTIO_PIPE_READ)
{
/* TODO: should specify ERRTOOUT */
/* TODO: should we specify ERRTOOUT? */
flags = QSE_PCP_READOUT |
QSE_PCP_ERRTOOUT;
QSE_PCP_ERRTOOUT;
}
else if (epa->mode == QSE_AWK_EXTIO_PIPE_WRITE)
{
flags = QSE_PCP_WRITEIN;
}
else if (epa->mode == QSE_AWK_EXTIO_PIPE_RW)
{
flags = QSE_PCP_READOUT |
QSE_PCP_ERRTOOUT |
QSE_PCP_WRITEIN;
}
else return -1; /* TODO: any way to set the error number? */
/*dprint (QSE_T("opening %s of type %d (pipe)\n"), epa->name, epa->type);*/