mirror of
https://github.com/vxunderground/VX-API
synced 2026-06-06 16:54:55 +00:00
Create EhWin32FromHResult.cpp
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
DWORD EhWin32FromHResult(HRESULT Result)
|
||||
{
|
||||
if ((Result & 0xFFFF0000) == MAKE_HRESULT(SEVERITY_ERROR, FACILITY_WIN32, 0))
|
||||
return HRESULT_CODE(Result);
|
||||
|
||||
if (Result == S_OK)
|
||||
return ERROR_SUCCESS;
|
||||
|
||||
return ERROR_CAN_NOT_COMPLETE;
|
||||
}
|
||||
Reference in New Issue
Block a user