[PATCH 1/5] avicap32: Define NONAMELESSUNION in files that include objidl.h.
Zebediah Figura
zfigura at codeweavers.com
Tue Dec 17 11:55:08 CST 2019
On 12/17/19 11:37 AM, Alexandre Julliard wrote:
> Zebediah Figura <z.figura12 at gmail.com> writes:
>
>> Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=47710
>> Signed-off-by: Zebediah Figura <z.figura12 at gmail.com>
>> ---
>> This is not currently necessary, but will be with the prescribed solution for
>> bug 47710, viz. defining the type _STGMEDIUM_UNION.
>
> I'm not sure I understand what fix you are proposing, but if it requires
> Winelib users to also define NONAMELESSUNION I don't think it's a viable
> solution.
>
Essentially, this:
---
diff --git a/include/objidl.idl b/include/objidl.idl
index a0ad1f6e01f..4c56c422747 100644
--- a/include/objidl.idl
+++ b/include/objidl.idl
@@ -1427,7 +1427,7 @@ interface IAdviseSink : IUnknown
} GDI_OBJECT;
typedef struct _userSTGMEDIUM {
- union switch(DWORD tymed) u {
+ union _STGMEDIUM_UNION switch(DWORD tymed) u {
case TYMED_NULL: ;
case TYMED_MFPICT: wireHMETAFILEPICT hMetaFilePict;
case TYMED_ENHMF: wireHENHMETAFILE hHEnhMetaFile;
---
Which causes warnings anywhere that nameless unions are used:
---
In file included from ../../../wine/include/objbase.h:258,
from ../../../wine/include/ole2.h:25,
from ../../include/strmif.h:13,
from ../../../wine/dlls/wmcodecdspuuid/wmcodecdspuuid.c:22:
../../include/objidl.h:6109:21: warning: declaration does not declare
anything
6109 | } DUMMYUNIONNAME;
| ^
---
More information about the wine-devel
mailing list