This commit is contained in:
Igor Pavlov
2023-12-22 17:17:05 +00:00
committed by Kornel
parent ec44a8a070
commit a36c48cece
954 changed files with 42199 additions and 25482 deletions

View File

@@ -19,8 +19,8 @@ namespace NError {
static bool MyFormatMessage(DWORD errorCode, UString &message)
{
#ifndef _SFX
if ((HRESULT)errorCode == MY_HRES_ERROR__INTERNAL_ERROR)
#ifndef Z7_SFX
if ((HRESULT)errorCode == MY_HRES_ERROR_INTERNAL_ERROR)
{
message = "Internal Error: The failure in hardware (RAM or CPU), OS or program";
return true;
@@ -72,7 +72,7 @@ static bool MyFormatMessage(DWORD errorCode, UString &message)
case E_OUTOFMEMORY : s = "E_OUTOFMEMORY : Can't allocate required memory"; break;
case E_INVALIDARG : s = "E_INVALIDARG : One or more arguments are invalid"; break;
// case MY__E_ERROR_NEGATIVE_SEEK : s = "MY__E_ERROR_NEGATIVE_SEEK"; break;
// case MY_E_ERROR_NEGATIVE_SEEK : s = "MY_E_ERROR_NEGATIVE_SEEK"; break;
default:
break;
}
@@ -81,7 +81,7 @@ static bool MyFormatMessage(DWORD errorCode, UString &message)
So we must transfer error codes before strerror() */
if (!s)
{
if ((errorCode & 0xFFFF0000) == (UInt32)((MY__FACILITY__WRes << 16) | 0x80000000))
if ((errorCode & 0xFFFF0000) == (UInt32)((MY_FACILITY_WRes << 16) | 0x80000000))
errorCode &= 0xFFFF;
else if ((errorCode & ((UInt32)1 << 31)))
return false; // we will show hex error later for that case