MCPcopy Create free account
hub / github.com/clechasseur/pathcopycopy / QueryDWORDValue

Method QueryDWORDValue

PathCopyCopy/src/UserOverrideableRegKey.cpp:113–126  ·  view source on GitHub ↗

Tries to load a DWORD value from the registry key. @param p_pValueName Name of value to load. @param p_rValue Where to store value. @return Result code (ERROR_SUCCESS if it worked).

Source from the content-addressed store, hash-verified

111// @return Result code (ERROR_SUCCESS if it worked).
112//
113long UserOverrideableRegKey::QueryDWORDValue(const wchar_t* const p_pValueName,
114 DWORD& p_rValue) const
115{
116 long res = ERROR_FILE_NOT_FOUND;
117 if (!Locked()) {
118 res = m_UserKey.QueryDWORDValue(p_pValueName, p_rValue);
119 } else {
120 res = ERROR_ACCESS_DENIED;
121 }
122 if (res != ERROR_SUCCESS && m_GlobalKey.Valid()) {
123 res = m_GlobalKey.QueryDWORDValue(p_pValueName, p_rValue);
124 }
125 return res;
126}
127
128//
129// Tries to load a QWORD value from the registry key.

Callers 1

LockedMethod · 0.45

Calls 1

ValidMethod · 0.45

Tested by

no test coverage detected