[ros-diffs] [akhaldi] 55177: [FUSION] * Sync to Wine 1.3.37.

akhaldi at svn.reactos.org akhaldi at svn.reactos.org
Wed Jan 25 19:09:24 UTC 2012


Author: akhaldi
Date: Wed Jan 25 19:09:23 2012
New Revision: 55177

URL: http://svn.reactos.org/svn/reactos?rev=55177&view=rev
Log:
[FUSION]
* Sync to Wine 1.3.37.

Added:
    trunk/reactos/dll/win32/fusion/version.rc   (with props)
Removed:
    trunk/reactos/dll/win32/fusion/fusion_ros.diff
Modified:
    trunk/reactos/dll/win32/fusion/CMakeLists.txt
    trunk/reactos/dll/win32/fusion/asmenum.c
    trunk/reactos/dll/win32/fusion/asmname.c
    trunk/reactos/dll/win32/fusion/fusion.rbuild
    trunk/reactos/dll/win32/fusion/fusionpriv.h
    trunk/reactos/media/doc/README.WINE

Modified: trunk/reactos/dll/win32/fusion/CMakeLists.txt
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/fusion/CMakeLists.txt?rev=55177&r1=55176&r2=55177&view=diff
==============================================================================
--- trunk/reactos/dll/win32/fusion/CMakeLists.txt [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/fusion/CMakeLists.txt [iso-8859-1] Wed Jan 25 19:09:23 2012
@@ -14,6 +14,7 @@
     assembly.c
     fusion.c
     fusion_main.c
+    version.rc
     ${CMAKE_CURRENT_BINARY_DIR}/fusion_stubs.c
     ${CMAKE_CURRENT_BINARY_DIR}/fusion.def)
 

Modified: trunk/reactos/dll/win32/fusion/asmenum.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/fusion/asmenum.c?rev=55177&r1=55176&r2=55177&view=diff
==============================================================================
--- trunk/reactos/dll/win32/fusion/asmenum.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/fusion/asmenum.c [iso-8859-1] Wed Jan 25 19:09:23 2012
@@ -236,9 +236,9 @@
     DWORD size, i;
 
     size = sizeof(name1);
-    IAssemblyName_GetProperty(asmname1->name, ASM_NAME_NAME, &name1, &size);
+    IAssemblyName_GetProperty(asmname1->name, ASM_NAME_NAME, name1, &size);
     size = sizeof(name2);
-    IAssemblyName_GetProperty(asmname2->name, ASM_NAME_NAME, &name2, &size);
+    IAssemblyName_GetProperty(asmname2->name, ASM_NAME_NAME, name2, &size);
 
     if ((ret = strcmpiW(name1, name2))) return ret;
 

Modified: trunk/reactos/dll/win32/fusion/asmname.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/fusion/asmname.c?rev=55177&r1=55176&r2=55177&view=diff
==============================================================================
--- trunk/reactos/dll/win32/fusion/asmname.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/fusion/asmname.c [iso-8859-1] Wed Jan 25 19:09:23 2012
@@ -39,7 +39,7 @@
 WINE_DEFAULT_DEBUG_CHANNEL(fusion);
 
 typedef struct {
-    const IAssemblyNameVtbl *lpIAssemblyNameVtbl;
+    IAssemblyName IAssemblyName_iface;
 
     LPWSTR path;
 
@@ -67,10 +67,15 @@
 
 #define CHARS_PER_PUBKEY 16
 
+static inline IAssemblyNameImpl *impl_from_IAssemblyName(IAssemblyName *iface)
+{
+    return CONTAINING_RECORD(iface, IAssemblyNameImpl, IAssemblyName_iface);
+}
+
 static HRESULT WINAPI IAssemblyNameImpl_QueryInterface(IAssemblyName *iface,
                                                        REFIID riid, LPVOID *ppobj)
 {
-    IAssemblyNameImpl *This = (IAssemblyNameImpl *)iface;
+    IAssemblyNameImpl *This = impl_from_IAssemblyName(iface);
 
     TRACE("(%p, %s, %p)\n", This, debugstr_guid(riid), ppobj);
 
@@ -90,7 +95,7 @@
 
 static ULONG WINAPI IAssemblyNameImpl_AddRef(IAssemblyName *iface)
 {
-    IAssemblyNameImpl *This = (IAssemblyNameImpl *)iface;
+    IAssemblyNameImpl *This = impl_from_IAssemblyName(iface);
     ULONG refCount = InterlockedIncrement(&This->ref);
 
     TRACE("(%p)->(ref before = %u)\n", This, refCount - 1);
@@ -100,7 +105,7 @@
 
 static ULONG WINAPI IAssemblyNameImpl_Release(IAssemblyName *iface)
 {
-    IAssemblyNameImpl *This = (IAssemblyNameImpl *)iface;
+    IAssemblyNameImpl *This = impl_from_IAssemblyName(iface);
     ULONG refCount = InterlockedDecrement(&This->ref);
 
     TRACE("(%p)->(ref before = %u)\n", This, refCount + 1);
@@ -111,6 +116,7 @@
         HeapFree(GetProcessHeap(), 0, This->displayname);
         HeapFree(GetProcessHeap(), 0, This->name);
         HeapFree(GetProcessHeap(), 0, This->culture);
+        HeapFree(GetProcessHeap(), 0, This->procarch);
         HeapFree(GetProcessHeap(), 0, This);
     }
 
@@ -131,7 +137,7 @@
                                                     LPVOID pvProperty,
                                                     LPDWORD pcbProperty)
 {
-    IAssemblyNameImpl *name = (IAssemblyNameImpl *)iface;
+    IAssemblyNameImpl *name = impl_from_IAssemblyName(iface);
 
     TRACE("(%p, %d, %p, %p)\n", iface, PropertyId, pvProperty, pcbProperty);
 
@@ -222,7 +228,7 @@
                                                        LPDWORD pccDisplayName,
                                                        DWORD dwDisplayFlags)
 {
-    IAssemblyNameImpl *name = (IAssemblyNameImpl *)iface;
+    IAssemblyNameImpl *name = impl_from_IAssemblyName(iface);
     WCHAR verstr[30];
     DWORD size;
     LPWSTR cultureval = 0;
@@ -362,7 +368,7 @@
                                                 LPDWORD lpcwBuffer,
                                                 WCHAR *pwzName)
 {
-    IAssemblyNameImpl *name = (IAssemblyNameImpl *)iface;
+    IAssemblyNameImpl *name = impl_from_IAssemblyName(iface);
 
     TRACE("(%p, %p, %p)\n", iface, lpcwBuffer, pwzName);
 
@@ -383,7 +389,7 @@
                                                    LPDWORD pdwVersionHi,
                                                    LPDWORD pdwVersionLow)
 {
-    IAssemblyNameImpl *name = (IAssemblyNameImpl *)iface;
+    IAssemblyNameImpl *name = impl_from_IAssemblyName(iface);
 
     TRACE("(%p, %p, %p)\n", iface, pdwVersionHi, pdwVersionLow);
 
@@ -430,11 +436,16 @@
 };
 
 /* Internal methods */
+static inline IAssemblyNameImpl *unsafe_impl_from_IAssemblyName(IAssemblyName *iface)
+{
+    assert(iface->lpVtbl == &AssemblyNameVtbl);
+
+    return impl_from_IAssemblyName(iface);
+}
+
 HRESULT IAssemblyName_SetPath(IAssemblyName *iface, LPCWSTR path)
 {
-    IAssemblyNameImpl *name = (IAssemblyNameImpl *)iface;
-
-    assert(name->lpIAssemblyNameVtbl == &AssemblyNameVtbl);
+    IAssemblyNameImpl *name = unsafe_impl_from_IAssemblyName(iface);
 
     name->path = strdupW(path);
     if (!name->path)
@@ -446,9 +457,7 @@
 HRESULT IAssemblyName_GetPath(IAssemblyName *iface, LPWSTR buf, ULONG *len)
 {
     ULONG buffer_size = *len;
-    IAssemblyNameImpl *name = (IAssemblyNameImpl *)iface;
-
-    assert(name->lpIAssemblyNameVtbl == &AssemblyNameVtbl);
+    IAssemblyNameImpl *name = unsafe_impl_from_IAssemblyName(iface);
 
     if (!name->path)
         return S_OK;
@@ -561,7 +570,10 @@
     str = strdupW(szAssemblyName);
     save = str;
     if (!str)
-        return E_OUTOFMEMORY;
+    {
+        hr = E_OUTOFMEMORY;
+        goto done;
+    }
 
     ptr = strchrW(str, ',');
     if (ptr) *ptr = '\0';
@@ -575,7 +587,10 @@
 
     name->name = strdupW(str);
     if (!name->name)
-        return E_OUTOFMEMORY;
+    {
+        hr = E_OUTOFMEMORY;
+        goto done;
+    }
 
     if (!ptr)
         goto done;
@@ -621,7 +636,8 @@
         else if (!lstrcmpW(str, procarch))
         {
             name->procarch = strdupW(ptr);
-            hr = S_OK;
+            if (!name->procarch)
+                hr = E_OUTOFMEMORY;
         }
 
         if (FAILED(hr))
@@ -664,7 +680,7 @@
     if (!name)
         return E_OUTOFMEMORY;
 
-    name->lpIAssemblyNameVtbl = &AssemblyNameVtbl;
+    name->IAssemblyName_iface.lpVtbl = &AssemblyNameVtbl;
     name->ref = 1;
 
     hr = parse_display_name(name, szAssemblyName);
@@ -674,7 +690,7 @@
         return hr;
     }
 
-    *ppAssemblyNameObj = (IAssemblyName *)name;
-
-    return S_OK;
-}
+    *ppAssemblyNameObj = &name->IAssemblyName_iface;
+
+    return S_OK;
+}

Modified: trunk/reactos/dll/win32/fusion/fusion.rbuild
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/fusion/fusion.rbuild?rev=55177&r1=55176&r2=55177&view=diff
==============================================================================
--- trunk/reactos/dll/win32/fusion/fusion.rbuild [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/fusion/fusion.rbuild [iso-8859-1] Wed Jan 25 19:09:23 2012
@@ -15,4 +15,5 @@
 	<file>assembly.c</file>
 	<file>fusion.c</file>
 	<file>fusion_main.c</file>
+	<file>version.rc</file>
 </module>

Removed: trunk/reactos/dll/win32/fusion/fusion_ros.diff
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/fusion/fusion_ros.diff?rev=55176&view=auto
==============================================================================
--- trunk/reactos/dll/win32/fusion/fusion_ros.diff [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/fusion/fusion_ros.diff (removed)
@@ -1,11 +1,0 @@
---- dll\win32\fusion\fusion_main - Kopie.c	Fr Sep  5 17:28:27 2008
-+++ dll\win32\fusion\fusion_main.c	Mi Sep 10 10:38:55 2008
-@@ -34,8 +34,6 @@
- 
-     switch (fdwReason)
-     {
--        case DLL_WINE_PREATTACH:
--            return FALSE;    /* prefer native version */
-         case DLL_PROCESS_ATTACH:
-             DisableThreadLibraryCalls(hinstDLL);
-             break;

Modified: trunk/reactos/dll/win32/fusion/fusionpriv.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/fusion/fusionpriv.h?rev=55177&r1=55176&r2=55177&view=diff
==============================================================================
--- trunk/reactos/dll/win32/fusion/fusionpriv.h [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/fusion/fusionpriv.h [iso-8859-1] Wed Jan 25 19:09:23 2012
@@ -428,16 +428,16 @@
 struct tagASSEMBLY;
 typedef struct tagASSEMBLY ASSEMBLY;
 
-HRESULT assembly_create(ASSEMBLY **out, LPCWSTR file);
-HRESULT assembly_release(ASSEMBLY *assembly);
-HRESULT assembly_get_name(ASSEMBLY *assembly, LPWSTR *name);
-HRESULT assembly_get_path(const ASSEMBLY *assembly, LPWSTR *path);
-HRESULT assembly_get_version(ASSEMBLY *assembly, LPWSTR *version);
-BYTE assembly_get_architecture(ASSEMBLY *assembly);
-HRESULT assembly_get_pubkey_token(ASSEMBLY *assembly, LPWSTR *token);
-
-extern HRESULT IAssemblyName_SetPath(IAssemblyName *iface, LPCWSTR path);
-extern HRESULT IAssemblyName_GetPath(IAssemblyName *iface, LPWSTR buf, ULONG *len);
+HRESULT assembly_create(ASSEMBLY **out, LPCWSTR file) DECLSPEC_HIDDEN;
+HRESULT assembly_release(ASSEMBLY *assembly) DECLSPEC_HIDDEN;
+HRESULT assembly_get_name(ASSEMBLY *assembly, LPWSTR *name) DECLSPEC_HIDDEN;
+HRESULT assembly_get_path(const ASSEMBLY *assembly, LPWSTR *path) DECLSPEC_HIDDEN;
+HRESULT assembly_get_version(ASSEMBLY *assembly, LPWSTR *version) DECLSPEC_HIDDEN;
+BYTE assembly_get_architecture(ASSEMBLY *assembly) DECLSPEC_HIDDEN;
+HRESULT assembly_get_pubkey_token(ASSEMBLY *assembly, LPWSTR *token) DECLSPEC_HIDDEN;
+
+extern HRESULT IAssemblyName_SetPath(IAssemblyName *iface, LPCWSTR path) DECLSPEC_HIDDEN;
+extern HRESULT IAssemblyName_GetPath(IAssemblyName *iface, LPWSTR buf, ULONG *len) DECLSPEC_HIDDEN;
 
 static inline LPWSTR strdupW(LPCWSTR src)
 {
@@ -461,7 +461,7 @@
 {
     DWORD i;
 
-    static const WCHAR hexval[16] = {
+    static const WCHAR hexval[] = {
         '0','1','2','3','4','5','6','7','8','9','a','b','c','d','e','f'
     };
 

Added: trunk/reactos/dll/win32/fusion/version.rc
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/fusion/version.rc?rev=55177&view=auto
==============================================================================
--- trunk/reactos/dll/win32/fusion/version.rc (added)
+++ trunk/reactos/dll/win32/fusion/version.rc [iso-8859-1] Wed Jan 25 19:09:23 2012
@@ -1,0 +1,26 @@
+/*
+ * Copyright 2010 Louis Lenders
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+#define WINE_FILEDESCRIPTION_STR "Wine assembly manager"
+#define WINE_FILENAME_STR "fusion.dll"
+#define WINE_FILEVERSION 2,0,50727,4016
+#define WINE_FILEVERSION_STR "2.0.50727.4016"
+#define WINE_PRODUCTVERSION 2,0,50727,4016
+#define WINE_PRODUCTVERSION_STR "2.0.50727.4016"
+
+#include "wine/wine_common_ver.rc"

Propchange: trunk/reactos/dll/win32/fusion/version.rc
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: trunk/reactos/media/doc/README.WINE
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/media/doc/README.WINE?rev=55177&r1=55176&r2=55177&view=diff
==============================================================================
--- trunk/reactos/media/doc/README.WINE [iso-8859-1] (original)
+++ trunk/reactos/media/doc/README.WINE [iso-8859-1] Wed Jan 25 19:09:23 2012
@@ -60,7 +60,7 @@
 reactos/dll/win32/dbghelp         # Autosync
 reactos/dll/win32/dciman32        # Autosync
 reactos/dll/win32/dwmapi          # Synced to Wine-1.3.37
-reactos/dll/win32/fusion          # Autosync
+reactos/dll/win32/fusion          # Synced to Wine-1.3.37
 reactos/dll/win32/gdiplus         # Autosync
 reactos/dll/win32/hhctrl.ocx      # Autosync
 reactos/dll/win32/hlink           # Autosync
@@ -69,8 +69,8 @@
 reactos/dll/win32/iccvid          # Autosync
 reactos/dll/win32/icmp            # Synced to Wine-0_9_10
 reactos/dll/win32/imaadp32.acm    # Synced to Wine-1.3.37
+reactos/dll/win32/imagehlp        # Autosync
 reactos/dll/win32/imm32           # Autosync
-reactos/dll/win32/imagehlp        # Autosync
 reactos/dll/win32/inetcomm        # Autosync
 reactos/dll/win32/inetmib1        # Autosync
 reactos/dll/win32/initpki         # Autosync




More information about the Ros-diffs mailing list