Changeset 59385 in vbox for trunk/src/VBox/Main/src-all/win
- Timestamp:
- Jan 18, 2016 5:37:59 PM (9 years ago)
- svn:sync-xref-src-repo-rev:
- 105078
- Location:
- trunk/src/VBox/Main/src-all/win
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/src-all/win/VBoxProxyStub.c
r59370 r59385 69 69 # define VBSP_LOG_DEL_KEY(a) do { } while (0) 70 70 #endif 71 72 /** 73 * Selects the proxy stub DLL based on 32-on-64-bit and host OS version. 74 * 75 * The legacy DLL covers 64-bit pre Windows 7 versions of Windows. W2K3-amd64 76 * has trouble parsing the result when MIDL /target NT51 or higher. Vista and 77 * windows server 2008 seems to have trouble with newer IDL compilers. 78 */ 79 #define VBPS_PROXY_STUB_FILE(a_fIs32On64) \ 80 ( (a_fIs32On64) ? "x86\\VBoxProxyStub-x86.dll" \ 81 : RT_MAKE_U64(((PKUSER_SHARED_DATA)MM_SHARED_USER_DATA_VA)->NtMinorVersion, \ 82 ((PKUSER_SHARED_DATA)MM_SHARED_USER_DATA_VA)->NtMajorVersion) >= RT_MAKE_U64(1/*Lo*/,6/*Hi*/) \ 83 ? "VBoxProxyStub.dll" : "VBoxProxyStubLegacy.dll" ) 71 84 72 85 … … 142 155 /* Init IPRT. */ 143 156 RTR3InitDll(RTR3INIT_FLAGS_UNOBTRUSIVE); 157 158 #ifdef VBOX_STRICT 159 { 160 /* 161 * Check that no interface has more than 256 methods in the stub vtable. 162 */ 163 const ProxyFileInfo **ppProxyFile = &g_apProxyFiles[0]; 164 const ProxyFileInfo *pProxyFile; 165 while ((pProxyFile = *ppProxyFile++) != NULL) 166 { 167 const PCInterfaceStubVtblList * const papStubVtbls = pProxyFile->pStubVtblList; 168 const char * const *papszNames = pProxyFile->pNamesArray; 169 unsigned iIf = pProxyFile->TableSize; 170 AssertStmt(iIf < 1024, iIf = 0); 171 Assert(pProxyFile->TableVersion == 2); 172 173 while (iIf-- > 0) 174 AssertMsg(papStubVtbls[iIf]->header.DispatchTableCount <= 256, 175 ("%s: DispatchTableCount=%d\n", papszNames[iIf], papStubVtbls[iIf]->header.DispatchTableCount)); 176 } 177 } 178 #endif 144 179 break; 145 180 … … 1107 1142 unsigned i = pState->cAltDeletes; 1108 1143 while (i-- > 0) 1109 vbpsDeleteKeyRecursiveA(pState, pState->aAltDeletes[i].hkeyClsid, szClsId, __LINE__); 1144 if (pState->aAltDeletes[i].hkeyClsid != NULL) 1145 vbpsDeleteKeyRecursiveA(pState, pState->aAltDeletes[i].hkeyClsid, szClsId, __LINE__); 1110 1146 vbpsDeleteKeyRecursiveA(pState, pState->hkeyClsidRootDst, szClsId, __LINE__); 1111 1147 } … … 1232 1268 static void vbpsUpdateTypeLibRegistration(VBPSREGSTATE *pState, PCRTUTF16 pwszVBoxDir, bool fIs32On64) 1233 1269 { 1234 const char * const pszTypeLibDll = !fIs32On64 ? "VBoxProxyStub.dll" : "x86\\VBoxProxyStub-x86.dll";1270 const char * const pszTypeLibDll = VBPS_PROXY_STUB_FILE(fIs32On64); 1235 1271 const char * const pszWinXx = !fIs32On64 ? "win64" : "win32"; 1236 1272 const char * const pszDescription = "VirtualBox Type Library"; … … 1316 1352 * It's simple compared to the VBox classes, thus all the NULL parameters. 1317 1353 */ 1318 const char *pszPsDll = !fIs32On64 ? "VBoxProxyStub.dll" : "x86\\VBoxProxyStub-x86.dll";1354 const char *pszPsDll = VBPS_PROXY_STUB_FILE(fIs32On64); 1319 1355 Assert(pState->fUpdate && !pState->fDelete); 1320 1356 VbpsRegisterClassId(pState, &g_ProxyClsId, "PSFactoryBuffer", NULL /*pszAppId*/, -
trunk/src/VBox/Main/src-all/win/comregister.cmd
r59365 r59385 7 7 8 8 REM 9 REM Copyright (C) 2006-201 5Oracle Corporation9 REM Copyright (C) 2006-2016 Oracle Corporation 10 10 REM 11 11 REM This file is part of VirtualBox Open Source Edition (OSE), as … … 121 121 REM 122 122 set fNoProxy=0 123 if "%WinVerMajor%" == "5" set fNoProxy=1124 if "%WinVerMajor%" == "4" set fNoProxy=1125 123 set fUninstallOnly=0 126 124 … … 173 171 REM Unregister all first, then register them. The order matters here. 174 172 :register_amd64 173 if "%WinVerMajor%" == "5" goto register_amd64_legacy 174 if not "%WinVerMajor%" == "6" goto register_amd64_not_legacy 175 if not "%WinVerMinor%" == "0" goto register_amd64_not_legacy 176 :register_amd64_legacy 177 set s64BitProxyStub=VBoxProxyStubLegacy.dll 178 goto register_amd64_begin 179 :register_amd64_not_legacy 180 set s64BitProxyStub=VBoxProxyStub.dll 181 :register_amd64_begin 182 echo s64BitProxyStub=%s64BitProxyStub% 175 183 @echo on 176 184 "%_VBOX_DIR%VBoxSVC.exe" /UnregServer 177 185 %windir%\system32\regsvr32 /s /u "%_VBOX_DIR%VBoxC.dll" 178 186 %windir%\syswow64\regsvr32 /s /u "%_VBOX_DIR%x86\VBoxClient-x86.dll" 179 %windir%\system32\regsvr32 /s /u "%_VBOX_DIR% VBoxProxyStub.dll"187 %windir%\system32\regsvr32 /s /u "%_VBOX_DIR%%s64BitProxyStub%" 180 188 %windir%\syswow64\regsvr32 /s /u "%_VBOX_DIR%x86\VBoxProxyStub-x86.dll" 181 189 if %fUninstallOnly% == 1 goto end … … 184 192 %windir%\syswow64\regsvr32 /s "%_VBOX_DIR%x86\VBoxClient-x86.dll" 185 193 if %fNoProxy% == 1 goto end 186 if exist "%_VBOX_DIR% VBoxProxyStub.dll" %windir%\system32\regsvr32 /s "%_VBOX_DIR%VBoxProxyStub.dll"194 if exist "%_VBOX_DIR%%s64BitProxyStub%" %windir%\system32\regsvr32 /s "%_VBOX_DIR%%s64BitProxyStub%" 187 195 if exist "%_VBOX_DIR%x86\VBoxProxyStub-x86.dll" %windir%\syswow64\regsvr32 /s "%_VBOX_DIR%x86\VBoxProxyStub-x86.dll" 188 196 @echo off
Note:
See TracChangeset
for help on using the changeset viewer.