Skip to content
Snippets Groups Projects
Commit dfdb93cc authored by calrama's avatar calrama
Browse files

Stop crashing if windows registry querying fails

parent 54723f27
No related branches found
No related tags found
No related merge requests found
...@@ -76,11 +76,13 @@ std::vector<std::string> QueryKey(HKEY hKey, std::string path) ...@@ -76,11 +76,13 @@ std::vector<std::string> QueryKey(HKEY hKey, std::string path)
{ {
qWarning() << "Error opening registry path " << path.c_str(); qWarning() << "Error opening registry path " << path.c_str();
regKey.Close(); regKey.Close();
continue;
} }
if( ERROR_SUCCESS != regKey.QueryStringValue(achValue,szBuffer,&dwBufferSize)) if( ERROR_SUCCESS != regKey.QueryStringValue(achValue,szBuffer,&dwBufferSize))
{ {
qWarning() << "Error opening registry value " << achValue; qWarning() << "Error opening registry value " << achValue;
regKey.Close(); regKey.Close();
continue;
} }
std::string fp = szBuffer; std::string fp = szBuffer;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment