Removed unnecessary check.

This commit is contained in:
XMRig 2019-12-15 12:02:45 +07:00
parent b346507975
commit 6adba6dad4
No known key found for this signature in database
GPG Key ID: 446A53638BE94409

View File

@ -137,13 +137,6 @@ static HANDLE wrmsr_install_driver()
return nullptr;
}
err = GetLastError();
if (err != ERROR_SERVICE_DOES_NOT_EXIST) {
LOG_ERR(CLEAR "%s" RED_S "failed to open WinRing0 driver, error %u", tag, err);
return nullptr;
}
hService = CreateServiceW(hManager, SERVICE_NAME, SERVICE_NAME, SERVICE_ALL_ACCESS, SERVICE_KERNEL_DRIVER, SERVICE_DEMAND_START, SERVICE_ERROR_NORMAL, driverPath.c_str(), nullptr, nullptr, nullptr, nullptr, nullptr);
if (!hService) {
LOG_ERR(CLEAR "%s" RED_S "failed to install WinRing0 driver, error %u", tag, GetLastError());