Changeset 39462 in vbox
- Timestamp:
- Nov 29, 2011 5:49:01 PM (13 years ago)
- svn:sync-xref-src-repo-rev:
- 75110
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/VBoxService/VBoxServiceControlThread.cpp
r39461 r39462 322 322 static int VBoxServiceControlThreadCloseStdIn(RTPOLLSET hPollSet, PRTPIPE phStdInW) 323 323 { 324 AssertPtrReturn(phStdInW, VERR_INVALID_POINTER); 325 324 326 int rc = RTPollSetRemove(hPollSet, VBOXSERVICECTRLPIPEID_STDIN); 325 327 if (rc != VERR_POLL_HANDLE_ID_NOT_FOUND) 326 328 AssertRC(rc); 327 329 328 rc = RTPipeClose(*phStdInW); 329 AssertRC(rc); 330 *phStdInW = NIL_RTPIPE; 330 if (*phStdInW != NIL_RTPIPE) 331 { 332 rc = RTPipeClose(*phStdInW); 333 AssertRC(rc); 334 *phStdInW = NIL_RTPIPE; 335 } 331 336 332 337 return rc; … … 453 458 454 459 size_t cbWritten = 0; 455 if (*phStdInW != NIL_RTPIPE) 460 if ( *phStdInW != NIL_RTPIPE 461 && pRequest->cbData) 456 462 { 457 463 rcReq = RTPipeWrite(*phStdInW, … … 466 472 * the poll set. 467 473 */ 468 if ( pRequest->enmType == VBOXSERVICECTRLREQUEST_STDIN_WRITE_EOF )474 if ( pRequest->enmType == VBOXSERVICECTRLREQUEST_STDIN_WRITE_EOF 469 475 && pRequest->cbData == cbWritten) 470 476 { 471 477 rc = VBoxServiceControlThreadCloseStdIn(hPollSet, phStdInW); 472 478 } 473 479
Note:
See TracChangeset
for help on using the changeset viewer.