VirtualBox

Ignore:
Timestamp:
Jul 8, 2008 4:26:13 PM (17 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
33025
Message:

Implemented the IDC methods. Moved the setting of the R0Process and Process SUPDRVSESSION members to SUPDrv.c, and made SUPDrv.c provide default initialization of the Uid and Gid members.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/HostDrivers/Support/win/SUPDrv-win.cpp

    r10265 r10377  
    232232    pFileObj->FsContext = NULL;
    233233    PSUPDRVSESSION pSession;
    234     int rc = supdrvCreateSession(pDevExt, &pSession);
     234#if 0 /** @todo check if this works, consider OBJ_KERNEL_HANDLE too. */
     235    bool fUser = pIrp->RequestorMode != KernelMode;
     236#else
     237    bool fUser = true;
     238#endif
     239    int rc = supdrvCreateSession(pDevExt, fUser, &pSession);
    235240    if (!rc)
    236     {
    237         pSession->Uid       = NIL_RTUID;
    238         pSession->Gid       = NIL_RTGID;
    239         pSession->Process   = RTProcSelf();
    240         pSession->R0Process = RTR0ProcHandleSelf();
    241241        pFileObj->FsContext = pSession;
    242     }
    243242
    244243    NTSTATUS    rcNt = pIrp->IoStatus.Status = VBoxDrvNtErr2NtStatus(rc);
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette