- Timestamp:
- Mar 22, 2007 6:57:25 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Serial/DrvChar.cpp
r1533 r1646 248 248 return PDMDrvHlpVMSetError(pDrvIns, VERR_PDM_MISSING_INTERFACE_BELOW, RT_SRC_POS, N_("Char#%d has no stream interface below"), pDrvIns->iInstance); 249 249 250 rc = RTThreadCreate(&pData->ReceiveThread, drvCharReceiveLoop, (void *)pData, 0, RTTHREADTYPE_IO, 0, "Char");250 rc = RTThreadCreate(&pData->ReceiveThread, drvCharReceiveLoop, (void *)pData, 0, RTTHREADTYPE_IO, RTTHREADFLAGS_WAITABLE, "Char"); 251 251 if (VBOX_FAILURE(rc)) 252 252 return PDMDrvHlpVMSetError(pDrvIns, rc, RT_SRC_POS, N_("Char#%d cannot create receive thread"), pDrvIns->iInstance); … … 273 273 * (the api is relatively new, which is why it's not used in all the places it should.) */ 274 274 pData->fShutdown = true; 275 for (int i = 0; i < 100; i++) 276 { 277 if (pData->ReceiveThread == NIL_RTTHREAD) 278 break; 279 RTThreadSleep(100); 280 } 275 RTThreadWait(pData->ReceiveThread, 1000, NULL); 281 276 if (pData->ReceiveThread != NIL_RTTHREAD) 282 277 LogRel(("Char%d: receive thread did not terminate\n", pDrvIns->iInstance));
Note:
See TracChangeset
for help on using the changeset viewer.