igoticecream Grandmaster Cheater Supreme
Reputation: 0
Joined: 23 Apr 2006 Posts: 1807 Location: 0x00400000
|
Posted: Mon Mar 09, 2009 9:53 pm Post subject: Driver unloading without cancelling operations |
|
|
thats the error that i get on unloading a driver i made
"DRIVER_UNLOADED_WITHOUT_CANCELLING_PENDING_OPERATION"
Why this error popup on a cute blue screen only when unloading? this is my function of unload
usermode:
| Quote: |
void __fastcall TfrmMain::btnUnloadClick(TObject *Sender)
{
ControlService(hService, SERVICE_CONTROL_STOP, &ss);
CloseServiceHandle(hService);
DeleteService(hService);
CloseServiceHandle(hSCManager);
}
|
the unload function
| Code: |
void Unload(IN PDRIVER_OBJECT DriverObject)
{
UNICODE_STRING myDosDeviceName;
DisableInt();
// i restore some bytes here from a inline hook
EnableInt();
RtlInitUnicodeString(&myDosDeviceName, L"\\DosDevices\\Arepa");
IoDeleteSymbolicLink(&myDosDeviceName);
IoDeleteDevice(DriverObject->DeviceObject);
}
|
|
|