Changeset 38321 in vbox for trunk/src/VBox/HostDrivers/Support
- Timestamp:
- Aug 5, 2011 10:08:31 AM (13 years ago)
- Location:
- trunk/src/VBox/HostDrivers/Support
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostDrivers/Support/SUPDrv.c
r38075 r38321 1852 1852 if (pReq->Hdr.pSession != NULL) 1853 1853 { 1854 OSDBGPRINT(("SUPDRV_IDC_REQ_CONNECT: pSession=%p expected NULL!\n", pReq->Hdr.pSession));1854 OSDBGPRINT(("SUPDRV_IDC_REQ_CONNECT: Hdr.pSession=%p expected NULL!\n", pReq->Hdr.pSession)); 1855 1855 return pReqHdr->rc = VERR_INVALID_PARAMETER; 1856 1856 } … … 1866 1866 OSDBGPRINT(("SUPDRV_IDC_REQ_CONNECT: uMinVersion=%#x uMaxVersion=%#x doesn't match!\n", 1867 1867 pReq->u.In.uMinVersion, pReq->u.In.uReqVersion)); 1868 return pReqHdr->rc = VERR_INVALID_PARAMETER; 1869 } 1870 if (pSession != NULL) 1871 { 1872 OSDBGPRINT(("SUPDRV_IDC_REQ_CONNECT: pSession=%p expected NULL!\n", pSession)); 1868 1873 return pReqHdr->rc = VERR_INVALID_PARAMETER; 1869 1874 } … … 1891 1896 pReq->u.Out.uDriverRevision = VBOX_SVN_REV; 1892 1897 1893 /*1894 * On NT we will already have a session associated with the1895 * client, just like with the SUP_IOCTL_COOKIE request, while1896 * the other doesn't.1897 */1898 #ifdef RT_OS_WINDOWS1899 pReq->Hdr.rc = VINF_SUCCESS;1900 #else1901 AssertReturn(!pSession, VERR_INTERNAL_ERROR);1902 1898 pReq->Hdr.rc = supdrvCreateSession(pDevExt, false /* fUser */, &pSession); 1903 1899 if (RT_FAILURE(pReq->Hdr.rc)) … … 1906 1902 return VINF_SUCCESS; 1907 1903 } 1908 #endif1909 1904 1910 1905 pReq->u.Out.pSession = pSession; -
trunk/src/VBox/HostDrivers/Support/win/SUPDrv-win.cpp
r38075 r38321 484 484 { 485 485 /* Verify the pDevExt in the session. */ 486 if ( ( !pSession487 && pStack->Parameters.DeviceIoControl.IoControlCode == SUPDRV_IDC_REQ_CONNECT)488 || ( VALID_PTR(pSession)489 && pSession->pDevExt == pDevExt))486 if ( pStack->Parameters.DeviceIoControl.IoControlCode != SUPDRV_IDC_REQ_CONNECT 487 ? VALID_PTR(pSession) && pSession->pDevExt == pDevExt 488 : !pSession 489 ) 490 490 { 491 491 /* Verify that the size in the request header is correct. */ … … 501 501 if (!rc) 502 502 { 503 if (pStack->Parameters.DeviceIoControl.IoControlCode == SUPDRV_IDC_REQ_CONNECT) 504 pFileObj->FsContext = ((PSUPDRVIDCREQCONNECT)pHdr)->u.Out.pSession; 505 /** @todo Handle SUPDRV_IDC_REQ_DISCONNECT and drop the 506 * windows hack in the generic code. */ 507 503 508 rcNt = STATUS_SUCCESS; 504 509 cbOut = pHdr->cb; -
trunk/src/VBox/HostDrivers/Support/win/SUPR0IdcClient-win.c
r33540 r38321 119 119 { 120 120 pHandle->s.pDeviceObject = pDeviceObject; 121 pHandle->s.pFileObject = pFileObject;121 pHandle->s.pFileObject = pFileObject; 122 122 return rc; 123 123 }
Note:
See TracChangeset
for help on using the changeset viewer.