Changeset 4af261cfb396…
Parent 870c22af24f7…
by
Changes to one file · Browse files at 4af261cfb396 Showing diff from parent 870c22af24f7 Diff from another changeset...
@@ -111,11 +111,15 @@ rv = RegQueryValueExA(
hkey, name.c_str(), 0, 0, Data, &cbData);
- if (rv != ERROR_SUCCESS)
- return 0;
+ int ret = 0;
+ if (rv == ERROR_SUCCESS)
+ {
+ res = reinterpret_cast<const char*>(&Data);
+ ret = 1;
+ }
- res = reinterpret_cast<const char*>(&Data);
- return 1;
+ RegCloseKey(hkey);
+ return ret;
}
|
Loading...