Lines Matching refs:orc

101     APIRET  orc = DosCreateEventSem(NULL, &hev, DC_SEM_SHARED, FALSE);
102 if (orc == NO_ERROR)
104 orc = DosSetNPipeSem(pThis->hPipe, (HSEM)hev, 1);
105 if (orc == NO_ERROR)
113 return RTErrConvertFromOS2(orc);
126 APIRET orc;
145 orc = DosCreateNPipe((PSZ)szName, &hPipeR, fOpenMode, fPipeMode, RTPIPE_OS2_SIZE, RTPIPE_OS2_SIZE, NP_DEFAULT_WAIT);
146 if (orc == NO_ERROR)
148 orc = DosConnectNPipe(hPipeR);
149 if (orc == ERROR_PIPE_NOT_CONNECTED || orc == NO_ERROR)
159 orc = DosOpen((PSZ)szName, &hPipeW, &ulAction, 0 /*cbFile*/, FILE_NORMAL,
161 if (orc == NO_ERROR)
166 if ( orc != ERROR_PIPE_BUSY /* already exist - compatible */
167 && orc != ERROR_ACCESS_DENIED /* already exist - incompatible (?) */)
168 return RTErrConvertFromOS2(orc);
275 APIRET orc = DosQueryHType(hNative, &ulType, &ulAttr);
276 AssertMsgReturn(orc == NO_ERROR, ("%d\n", orc), RTErrConvertFromOS2(orc));
285 orc = DosQueryNPipeInfo(hNative, 1, &Buf, sizeof(Buf));
286 if (orc != NO_ERROR)
289 AssertMsgFailed(("%d\n", orc));
296 orc = DosQueryNPHState(hNative, &fPipeState);
297 if (orc != NO_ERROR)
300 AssertMsgFailed(("%d\n", orc));
308 orc = DosQueryFHState(hNative, &fFileState);
309 AssertMsgReturn(orc == NO_ERROR, ("%d\n", orc), VERR_INVALID_HANDLE);
317 orc = DosSetFHState(hNative, (fFileState & (OPEN_FLAGS_WRITE_THROUGH | OPEN_FLAGS_FAIL_ON_ERROR | OPEN_FLAGS_NO_CACHE))
319 AssertMsgReturn(orc == NO_ERROR, ("%d\n", orc), RTErrConvertFromOS2(orc));
377 APIRET orc = DosSetNPHState(pThis->hPipe, NP_WAIT | NP_READMODE_BYTE);
378 if (orc != NO_ERROR)
380 if (orc != ERROR_BROKEN_PIPE && orc != ERROR_PIPE_NOT_CONNECTED)
381 return RTErrConvertFromOS2(orc);
408 APIRET orc = DosSetNPHState(pThis->hPipe, NP_NOWAIT | NP_READMODE_BYTE);
409 if (orc != NO_ERROR)
411 if (orc != ERROR_BROKEN_PIPE && orc != ERROR_PIPE_NOT_CONNECTED)
412 return RTErrConvertFromOS2(orc);
438 APIRET orc = DosQueryNPipeSemState(pThis->hev, &aStates[0], sizeof(aStates));
439 if (orc == NO_ERROR)
446 AssertMsgFailed(("%d / %d\n", orc, aStates[0].fStatus));
455 APIRET orc = DosPeekNPipe(pThis->hPipe, NULL, 0, &cbActual, &Avail, &ulState);
456 if (orc != NO_ERROR)
458 if (orc != ERROR_PIPE_BUSY)
459 AssertMsgFailed(("%d\n", orc));
485 APIRET orc = DosRead(pThis->hPipe, pvBuf, cbToRead, &cbActual);
486 if (orc == NO_ERROR)
493 else if (orc == ERROR_NO_DATA)
499 rc = RTErrConvertFromOS2(orc);
534 APIRET orc = DosRead(pThis->hPipe, pvBuf, cbToRead, &cbActual);
535 if (orc != NO_ERROR)
537 rc = RTErrConvertFromOS2(orc);
591 APIRET orc = DosQueryNPipeSemState((HSEM)pThis->hev, &aStates[0], sizeof(aStates));
592 if (orc == NO_ERROR)
600 AssertMsgFailed(("%d / %d\n", orc, aStates[0].fStatus));
612 APIRET orc = DosQueryNPipeInfo(pThis->hPipe, 1, &Buf, sizeof(Buf));
613 if (orc == NO_ERROR)
615 AssertMsgFailed(("%d\n", orc));
640 APIRET orc = DosWrite(pThis->hPipe, pvBuf, cbToWrite, &cbActual);
641 if (orc == NO_ERROR && cbActual == 0)
645 orc = DosWrite(pThis->hPipe, pvBuf, RT_MIN(cbAvail, cbToWrite), &cbActual);
648 if (orc == NO_ERROR)
656 rc = RTErrConvertFromOS2(orc);
697 APIRET orc = DosWrite(pThis->hPipe, pvBuf, cbToWrite, &cbActual);
698 if (orc != NO_ERROR)
700 rc = RTErrConvertFromOS2(orc);
738 APIRET orc = DosResetBuffer(pThis->hPipe);
739 if (orc != NO_ERROR)
741 int rc = RTErrConvertFromOS2(orc);
782 APIRET orc;
786 orc = DosResetEventSem(pThis->hev, &ulIgnore);
787 AssertMsg(orc == NO_ERROR || orc == ERROR_ALREADY_RESET, ("%d\n", orc));
791 orc = DosQueryNPipeSemState((HSEM)pThis->hev, &aStates[0], sizeof(aStates));
792 if (orc != NO_ERROR)
794 rc = RTErrConvertFromOS2(orc);
830 orc = DosWaitEventSem(pThis->hev, cMsMaxWait);
832 if (orc != NO_ERROR && orc != ERROR_TIMEOUT && orc != ERROR_SEM_TIMEOUT )
834 rc = RTErrConvertFromOS2(orc);
865 APIRET orc = DosPeekNPipe(pThis->hPipe, NULL, 0, &cbActual, &Avail, &ulState);
866 if (orc == NO_ERROR)
874 rc = RTErrConvertFromOS2(orc);
915 APIRET orc;
919 orc = DosResetEventSem(pThis->hev, &ulIgnore);
920 AssertMsg(orc == NO_ERROR || orc == ERROR_ALREADY_RESET, ("%d\n", orc));
934 orc = DosPeekNPipe(pThis->hPipe, NULL, 0, &cbActual, &Avail, &ulState);
935 if (orc != NO_ERROR)
938 if (orc == ERROR_BROKEN_PIPE || orc == ERROR_PIPE_NOT_CONNECTED)
952 orc = DosQueryNPipeSemState((HSEM)pThis->hev, &aStates[0], sizeof(aStates));
953 if (orc == NO_ERROR)
970 if (orc == ERROR_BROKEN_PIPE || orc == ERROR_PIPE_NOT_CONNECTED)