| 136 | } |
| 137 | |
| 138 | bool RegistryUtilities::RegistryKeyExists(HKEY root_key, |
| 139 | const std::wstring& subkey) { |
| 140 | HKEY key_handle; |
| 141 | long registry_call_result = ::RegOpenKeyEx(root_key, |
| 142 | subkey.c_str(), |
| 143 | 0, |
| 144 | KEY_QUERY_VALUE, |
| 145 | &key_handle); |
| 146 | bool result = (ERROR_SUCCESS == registry_call_result); |
| 147 | if (result) { |
| 148 | ::RegCloseKey(key_handle); |
| 149 | } |
| 150 | return result; |
| 151 | } |
| 152 | |
| 153 | bool RegistryUtilities::Is64BitWindows() { |
| 154 | SYSTEM_INFO system_info; |
nothing calls this directly
no outgoing calls
no test coverage detected