DEVEL15-windows-backconnectionhostnames-20060817
authorJeffrey Altman <jaltman@secure-endpoints.com>
Thu, 17 Aug 2006 13:41:45 +0000 (13:41 +0000)
committerJeffrey Altman <jaltman@secure-endpoints.com>
Thu, 17 Aug 2006 13:41:45 +0000 (13:41 +0000)
FIXES 37807

uninitialized variable reported due to dwAllocSize not being used
within the initial RegQueryValueEx call.  (ugh)

(cherry picked from commit 16dc98ab4654f448909d59f65b2a8e3a55bc93b8)

src/WINNT/afsd/afsd_init.c

index 54b563f..120530c 100644 (file)
@@ -282,7 +282,7 @@ configureBackConnectionHostNames(void)
                        &hkMSV10) == ERROR_SUCCESS )
     {
         if (RegQueryValueEx( hkMSV10, "BackConnectionHostNames", 0, 
-                            &dwType, NULL, &dwSize) == ERROR_SUCCESS) {
+                            &dwType, NULL, &dwAllocSize) == ERROR_SUCCESS) {
            dwAllocSize += 1 /* in case the source string is not nul terminated */
                + strlen(cm_NetbiosName) + 2;
            pHostNames = malloc(dwAllocSize);