Author: pschweitzer
Date: Tue Jan 26 18:09:47 2016
New Revision: 70645
URL:
http://svn.reactos.org/svn/reactos?rev=70645&view=rev
Log:
[MPR]
Import Wine commit:
- 80eb2fa08eb21ba9504438493fa66097ed03faf5, Add support for REG_EXPAND_SZ for providers
path.
This fixes VMware network provider (vmhgfs.dll) not being able to be loaded in ReactOS.
CORE-10032
Modified:
trunk/reactos/dll/win32/mpr/wnet.c
Modified: trunk/reactos/dll/win32/mpr/wnet.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/mpr/wnet.c?rev=7…
==============================================================================
--- trunk/reactos/dll/win32/mpr/wnet.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/mpr/wnet.c [iso-8859-1] Tue Jan 26 18:09:47 2016
@@ -123,11 +123,17 @@
DWORD type, size = sizeof(providerPath);
if (RegQueryValueExW(hKey, szProviderPath, NULL, &type,
- (LPBYTE)providerPath, &size) == ERROR_SUCCESS && type == REG_SZ)
+ (LPBYTE)providerPath, &size) == ERROR_SUCCESS && (type == REG_SZ ||
type == REG_EXPAND_SZ))
{
static const WCHAR szProviderName[] = {
'N','a','m','e',0 };
PWSTR name = NULL;
-
+
+ if (type == REG_EXPAND_SZ)
+ {
+ WCHAR path[MAX_PATH];
+ if (ExpandEnvironmentStringsW(providerPath, path, MAX_PATH)) lstrcpyW(
providerPath, path );
+ }
+
size = 0;
RegQueryValueExW(hKey, szProviderName, NULL, NULL, NULL, &size);
if (size)