summaryrefslogtreecommitdiff
path: root/windowsRuntimeInstaller
diff options
context:
space:
mode:
authorLenny Komow <lenny@lunarg.com>2017-01-16 10:10:47 -0700
committerLenny Komow <lenny@lunarg.com>2017-01-16 10:12:42 -0700
commit9907912aeb9aadaecffbb12b776a1953303ae3ab (patch)
tree6245771040f8b39900ec118eb7fd985af3942c99 /windowsRuntimeInstaller
parent98fa844b22ed570ca2688e2e64d31b041ae01346 (diff)
winsdk: Fix RT not reading versions from registry
Change-Id: I44bb8c167492739467448925375ae1b99fb8a2db
Diffstat (limited to 'windowsRuntimeInstaller')
-rw-r--r--windowsRuntimeInstaller/configure_runtime.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/windowsRuntimeInstaller/configure_runtime.c b/windowsRuntimeInstaller/configure_runtime.c
index f952897d..d594bd3a 100644
--- a/windowsRuntimeInstaller/configure_runtime.c
+++ b/windowsRuntimeInstaller/configure_runtime.c
@@ -205,7 +205,8 @@ int main(int argc, char** argv)
fprintf(log, "API Name: %s\n", api_name);
// This makes System32 and SysWOW64 not do any redirection (well, until 128-bit is a thing)
- Wow64DisableWow64FsRedirection(NULL);
+ PVOID useless;
+ Wow64DisableWow64FsRedirection(&useless);
// Update System32 (on all systems) and SysWOW64 on 64-bit system
struct SDKVersion latest_runtime_version;
@@ -357,14 +358,14 @@ int find_installations(const char* api_name, char*** install_paths, struct SDKVe
for(int j = 0; j < valueCount; ++j) {
TCHAR name[COPY_BUFFER_SIZE], value[COPY_BUFFER_SIZE];
- DWORD type, buffSize = COPY_BUFFER_SIZE;
- RegEnumValue(subKey, j, name, &buffSize, NULL, &type, value, &buffSize);
+ DWORD type, nameSize = COPY_BUFFER_SIZE, valSize = COPY_BUFFER_SIZE;
+ LSTATUS ret = RegEnumValue(subKey, j, name, &nameSize, NULL, &type, value, &valSize);
if(type == REG_SZ && !strcmp("InstallDir", name)) {
*install_paths = realloc(*install_paths, sizeof(char*) * ((*count) + 1));
(*install_paths)[*count] = malloc(sizeof(char) * COPY_BUFFER_SIZE);
strcpy((*install_paths)[*count], value);
found_installation = true;
- } else if(type == REG_SZ && !strncmp("DisplayVersion", name, 8)) {
+ } else if(type == REG_SZ && !strcmp("DisplayVersion", name)) {
*install_versions = realloc(*install_versions, sizeof(struct SDKVersion) * ((*count) + 1));
CHECK_ERROR(read_version(value, (*install_versions) + *count));
found_version = true;