MCPcopy Create free account
hub / github.com/TombEngine/TombEngine / GetDWORDRegKey

Function GetDWORDRegKey

TombEngine/Specific/configuration.cpp:576–594  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

574}
575
576LONG GetDWORDRegKey(HKEY hKey, LPCSTR strValueName, DWORD* nValue, DWORD nDefaultValue)
577{
578 *nValue = nDefaultValue;
579
580 DWORD dwBufferSize(sizeof(DWORD));
581 DWORD nResult(0);
582 LONG nError = ::RegQueryValueEx(
583 hKey,
584 strValueName,
585 0,
586 NULL,
587 reinterpret_cast<LPBYTE>(&nResult),
588 &dwBufferSize);
589
590 if (ERROR_SUCCESS == nError)
591 *nValue = nResult;
592
593 return nError;
594}
595
596LONG GetBoolRegKey(HKEY hKey, LPCSTR strValueName, bool* bValue, bool bDefaultValue)
597{

Callers 2

LoadConfigurationFunction · 0.85
GetBoolRegKeyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected