diff options
author | Bram Moolenaar <Bram@vim.org> | 2010-08-02 22:13:25 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2010-08-02 22:13:25 +0200 |
commit | 61a91766f7558ae9914eb85377a32d7f6afe178c (patch) | |
tree | b84806f6a324c5c10b4d6b6a94a9f97e8c92d012 | |
parent | 4b22cdb0609090d59f8cec26b2493abe02ea48b7 (diff) | |
download | vim-git-61a91766f7558ae9914eb85377a32d7f6afe178c.tar.gz |
Take OLE registration back to 32 bit registry, the unregister wasn't working
for the 64 registry.
-rw-r--r-- | src/if_ole.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/src/if_ole.cpp b/src/if_ole.cpp index ff9e371a7..4c01f51d8 100644 --- a/src/if_ole.cpp +++ b/src/if_ole.cpp @@ -85,15 +85,6 @@ static CVim *app = 0; #define MAX_CLSID_LEN 100 -/* - * Modern way of creating registry entries, also works on 64 bit windows when - * compiled as a 32 bit program. - */ -# ifndef KEY_WOW64_64KEY -# define KEY_WOW64_64KEY 0x0100 -# define RegDeleteKeyEx(a, b, c, d) RegDeleteKey(a, b) -# endif - /***************************************************************************** 2. The application object *****************************************************************************/ @@ -167,7 +158,7 @@ CVim *CVim::Create(int *pbDoRestart) // RegCreateKeyEx succeeds even if key exists. W.Briscoe W2K 20021011 if (RegCreateKeyEx(HKEY_CLASSES_ROOT, MYVIPROGID, 0, NULL, REG_OPTION_NON_VOLATILE, - KEY_WOW64_64KEY | KEY_ALL_ACCESS, NULL, &hKey, NULL)) + KEY_ALL_ACCESS, NULL, &hKey, NULL)) { delete me; return NULL; // Unable to write to registry. Quietly fail. @@ -660,7 +651,7 @@ static void RecursiveDeleteKey(HKEY hKeyParent, const char *child) // Open the child HKEY hKeyChild; LONG result = RegOpenKeyEx(hKeyParent, child, 0, - KEY_WOW64_64KEY | KEY_ALL_ACCESS, &hKeyChild); + KEY_ALL_ACCESS, &hKeyChild); if (result != ERROR_SUCCESS) return; @@ -703,7 +694,7 @@ static void SetKeyAndValue(const char *key, const char *subkey, const char *valu long result = RegCreateKeyEx(HKEY_CLASSES_ROOT, buffer, 0, NULL, REG_OPTION_NON_VOLATILE, - KEY_WOW64_64KEY | KEY_ALL_ACCESS, NULL, + KEY_ALL_ACCESS, NULL, &hKey, NULL); if (result != ERROR_SUCCESS) return; |