Browse Source

Fix heap corruption. Closes #2342.

Fix heap corruption during Registry access.
adaptive-webui-19844
Vladimir Golovnev (Glassez) 10 years ago
parent
commit
b45eb28099
  1. 2
      src/preferences/preferences.cpp

2
src/preferences/preferences.cpp

@ -1394,7 +1394,7 @@ QString getRegValue(HKEY handle, const QString &name = QString()) @@ -1394,7 +1394,7 @@ QString getRegValue(HKEY handle, const QString &name = QString())
delete[] lpValueName;
if (res == ERROR_SUCCESS) {
lpData[cBuffer] = 0;
lpData[cBuffer - 1] = 0;
result = QString::fromWCharArray(lpData);
}
delete[] lpData;

Loading…
Cancel
Save