Dmitry Timoshkov dmitry@baikal.ru writes:
This version of the patch follows Windows behaviour by refusing to create an empty path in a region, and marks the test as broken when some Windows versions fail to properly clear an aligned DWORD.
dlls/gdiplus/region.c | 219 ++++++++++++++++++++++++++++++++++++++++---- dlls/gdiplus/tests/region.c | 65 +++++++++++++ 2 files changed, 266 insertions(+), 18 deletions(-)
diff --git a/dlls/gdiplus/region.c b/dlls/gdiplus/region.c index 832ce69..bc625f5 100644 --- a/dlls/gdiplus/region.c +++ b/dlls/gdiplus/region.c @@ -76,6 +76,28 @@ WINE_DEFAULT_DEBUG_CHANNEL(gdiplus); #define FLAGS_NOFLAGS 0x0 #define FLAGS_INTPATH 0x4000
+struct _memory_buffer +{
- const BYTE *buffer;
 - INT size, pos;
 +};
+struct _region_header +{
- DWORD size;
 - DWORD checksum;
 - DWORD magic;
 - DWORD num_children;
 +};
+struct _path_header +{
- DWORD size;
 - DWORD magic;
 - DWORD count;
 - DWORD flags;
 +};
There's no need to add leading underscores, it's obvious that these are not Windows types.