Lines Matching defs:rc

53     int rc = RTR3InitExeNoArguments(0);
54 if (RT_FAILURE(rc))
55 return RTMsgInitFailure(rc);
58 rc = RTStrToInt64Full(pszPipe, 10, &iNative);
59 if (RT_FAILURE(rc))
60 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTStrToUInt64Full(%s) -> %Rrc\n", pszPipe, rc);
63 rc = RTPipeFromNative(&hPipe, (RTHCINTPTR)iNative, RTPIPE_N_READ);
64 if (RT_FAILURE(rc))
65 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTPipeFromNative(,%s,READ) -> %Rrc\n", pszPipe, rc);
70 rc = RTPipeReadBlocking(hPipe, szTmp, sizeof(szTmp) - 1, &cbRead);
71 if (RT_FAILURE(rc))
72 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTPipeReadBlocking() -> %Rrc\n", rc);
77 rc = RTPipeReadBlocking(hPipe, szTmp2, sizeof(szTmp2), &cbRead2);
78 if (rc != VERR_BROKEN_PIPE)
79 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTPipeReadBlocking() -> %Rrc instead of VERR_BROKEN_PIPE\n", rc);
81 rc = RTPipeClose(hPipe);
82 if (RT_FAILURE(rc))
83 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTPipeClose() -> %Rrc\n", rc);
114 int rc;
115 RTTESTI_CHECK_RC(rc = RTPipeClose(hPipeW), VINF_SUCCESS);
116 if (RT_FAILURE(rc))
120 RTTESTI_CHECK_RC(rc = RTProcWait(hChild, RTPROCWAIT_FLAGS_BLOCK, &ProcStatus), VINF_SUCCESS);
121 if (RT_FAILURE(rc))
130 int rc = RTR3InitExeNoArguments(0);
131 if (RT_FAILURE(rc))
132 return RTMsgInitFailure(rc);
135 rc = RTStrToInt64Full(pszPipe, 10, &iNative);
136 if (RT_FAILURE(rc))
137 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTStrToUInt64Full(%s) -> %Rrc\n", pszPipe, rc);
140 rc = RTPipeFromNative(&hPipe, (RTHCINTPTR)iNative, RTPIPE_N_WRITE);
141 if (RT_FAILURE(rc))
142 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTPipeFromNative(,%s,WRITE) -> %Rrc\n", pszPipe, rc);
144 rc = RTPipeWriteBlocking(hPipe, g_szTest4Message, sizeof(g_szTest4Message) - 1, NULL);
145 if (RT_FAILURE(rc))
146 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTPipeWriteBlocking() -> %Rrc\n", rc);
148 rc = RTPipeClose(hPipe);
149 if (RT_FAILURE(rc))
150 return RTMsgErrorExit(RTEXITCODE_FAILURE, "RTPipeClose() -> %Rrc\n", rc);
178 int rc;
179 RTTESTI_CHECK_RC(rc = RTPipeReadBlocking(hPipeR, szTmp, sizeof(szTmp) - 1, &cbRead), VINF_SUCCESS);
180 if (RT_FAILURE(rc))
188 RTTESTI_CHECK_RC(rc = RTPipeClose(hPipeR), VINF_SUCCESS);
189 if (RT_FAILURE(rc))
193 RTTESTI_CHECK_RC(rc = RTProcWait(hChild, RTPROCWAIT_FLAGS_BLOCK, &ProcStatus), VINF_SUCCESS);
194 if (RT_FAILURE(rc))
212 int rc = VINF_SUCCESS;
222 rc = RTPipeWrite(hPipeW, s_abBuf, sizeof(s_abBuf), &cbWritten);
223 RTTESTI_CHECK_MSG(rc == VINF_SUCCESS || rc == VINF_TRY_AGAIN, ("rc=%Rrc\n", rc));
224 if (rc != VINF_SUCCESS)
229 if (rc == VINF_TRY_AGAIN)
240 rc = RTPipeWrite(hPipeW, s_abBuf, sizeof(s_abBuf), &cbWritten);
241 RTTESTI_CHECK(rc == VINF_SUCCESS);
301 int rc = RTPipeFlush(hPipeW);
302 RTTESTI_CHECK_MSG(rc == VERR_NOT_SUPPORTED || rc == VINF_SUCCESS, ("%Rrc\n", rc));
489 int rc = RTTestInitAndCreate("tstRTPipe", &hTest);
490 if (rc)
491 return rc;