status = KeWaitForSingleObject(&event, Executive, KernelMode, TRUE, NULL); if (!NT_SUCCESS(status)) { /* handle error */ }