afs-blacklist-initialize-volume-ptr-always-20080628
[openafs.git] / src / WINNT / afssvrcpa / cpl_interface.cpp
index bfdce49..014b83b 100644 (file)
@@ -1,10 +1,12 @@
 /*
- * Copyright (C) 1998  Transarc Corporation.
- * All rights reserved.
- *
+ * Copyright 2000, International Business Machines Corporation and others.
+ * All Rights Reserved.
+ * 
+ * This software has been released under the terms of the IBM Public
+ * License.  For details, see the LICENSE file in the top-level source
+ * directory or online at http://www.openafs.org/dl/license10.html
  */
 
-
 /*
  * INCLUDES _________________________________________________________________
  *
@@ -23,9 +25,9 @@
  * DEFINITIONS _______________________________________________________________
  *
  */
-#define APP_INSTALL_DIR_REG_KEY                AFSREG_SVR_SW_VERSION_KEY
+#define APP_INSTALL_DIR_REG_SUBKEY     AFSREG_SVR_SW_VERSION_SUBKEY
 #define APP_INSTALL_DIR_REG_VALUE      AFSREG_SVR_SW_VERSION_DIR_VALUE
-#define        APP_EXE_PATH                            "\\usr\\afs\\bin\\afssvrcfg.exe"
+#define        APP_EXE_PATH                    "\\usr\\afs\\bin\\afssvrcfg.exe"
 
 
 
@@ -59,7 +61,7 @@ static char *GetInstallDir()
 
        dwSize = sizeof(szInstallDir);
 
-       nResult = RegOpenKeyAlt(AFSREG_NULL_KEY, APP_INSTALL_DIR_REG_KEY, KEY_READ, FALSE, &hKey, 0);
+       nResult = RegOpenKeyAlt(HKEY_LOCAL_MACHINE, APP_INSTALL_DIR_REG_SUBKEY, KEY_READ, FALSE, &hKey, 0);
        if (nResult == ERROR_SUCCESS) {
                nResult = RegQueryValueEx(hKey, APP_INSTALL_DIR_REG_VALUE, 0, &dwType, (PBYTE)szInstallDir, &dwSize);
                RegCloseKey(hKey);