Rebase against 1bb953c6766c9cc4372ca23a7c5b7de101324218

This commit is contained in:
Alistair Leslie-Hughes 2020-01-30 10:21:06 +11:00
parent 59f43478d6
commit 44115dbd63
5 changed files with 48 additions and 147 deletions

View File

@ -1,21 +1,21 @@
From 9618572cf2eace39198fb83b747a70d1865015e3 Mon Sep 17 00:00:00 2001
From 540ee9ebdee96f7c67224bfae699375c8cb4c90c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Wed, 28 May 2014 19:50:51 +0200
Subject: [PATCH] loader: Add commandline option --check-libs.
---
include/wine/library.h | 2 +
libs/wine/config.c | 124 +++++++++++++++++++++++++++++++++++++++++++++++++
libs/wine/loader.c | 36 ++++++++++++++
libs/wine/config.c | 124 +++++++++++++++++++++++++++++++++++++++++
libs/wine/loader.c | 36 ++++++++++++
libs/wine/wine.map | 2 +
loader/main.c | 50 +++++++++++++++++++-
loader/main.c | 50 ++++++++++++++++-
5 files changed, 213 insertions(+), 1 deletion(-)
diff --git a/include/wine/library.h b/include/wine/library.h
index fae73fe..7395a11 100644
index 511bf4722a0..557cec20cf8 100644
--- a/include/wine/library.h
+++ b/include/wine/library.h
@@ -40,6 +40,7 @@ extern "C" {
@@ -44,6 +44,7 @@ extern "C" {
extern const char *wine_get_build_dir(void);
extern const char *wine_get_config_dir(void);
extern const char *wine_get_data_dir(void);
@ -23,7 +23,7 @@ index fae73fe..7395a11 100644
extern const char *wine_get_server_dir(void);
extern const char *wine_get_user_name(void);
extern const char *wine_get_version(void);
@@ -52,6 +53,7 @@ extern void wine_exec_wine_binary( const char *name, char **argv, const char *en
@@ -56,6 +57,7 @@ extern void wine_exec_wine_binary( const char *name, char **argv, const char *en
typedef void (*load_dll_callback_t)( void *, const char * );
@ -32,10 +32,10 @@ index fae73fe..7395a11 100644
extern void *wine_dlsym( void *handle, const char *symbol, char *error, size_t errorsize );
extern int wine_dlclose( void *handle, char *error, size_t errorsize );
diff --git a/libs/wine/config.c b/libs/wine/config.c
index 5da6263..6cedfb7 100644
index 5b66c063db6..e0988513e14 100644
--- a/libs/wine/config.c
+++ b/libs/wine/config.c
@@ -488,6 +488,130 @@ const char *wine_get_build_dir(void)
@@ -470,6 +470,130 @@ const char *wine_get_build_dir(void)
return build_dir;
}
@ -167,13 +167,14 @@ index 5da6263..6cedfb7 100644
const char *wine_get_server_dir(void)
{
diff --git a/libs/wine/loader.c b/libs/wine/loader.c
index 649aa22..367dde3 100644
index 2a569f5b739..5f10c3f9d3e 100644
--- a/libs/wine/loader.c
+++ b/libs/wine/loader.c
@@ -1064,6 +1064,42 @@ void *wine_dlopen( const char *filename, int flag, char *error, size_t errorsize
@@ -1072,6 +1072,42 @@ void *wine_dlopen( const char *filename, int flag, char *error, size_t errorsize
return ret;
}
/***********************************************************************
+/***********************************************************************
+ * wine_dladdr
+ */
+int wine_dladdr( void *addr, void *info, char *error, size_t errorsize )
@ -209,23 +210,22 @@ index 649aa22..367dde3 100644
+#endif
+}
+
+/***********************************************************************
/***********************************************************************
* wine_dlsym
*/
void *wine_dlsym( void *handle, const char *symbol, char *error, size_t errorsize )
diff --git a/libs/wine/wine.map b/libs/wine/wine.map
index 7cb2918..72ffed8 100644
index 5edee0d9235..8e3382168d5 100644
--- a/libs/wine/wine.map
+++ b/libs/wine/wine.map
@@ -65,6 +65,7 @@ WINE_1.0
wine_dbg_sprintf;
wine_dbgstr_an;
wine_dbgstr_wn;
@@ -16,6 +16,7 @@ WINE_1.0
wine_cp_wcstombs;
wine_cpsymbol_mbstowcs;
wine_cpsymbol_wcstombs;
+ wine_dladdr;
wine_dlclose;
wine_dll_enum_load_path;
wine_dll_get_owner;
@@ -85,6 +86,7 @@ WINE_1.0
wine_dll_set_callback;
@@ -32,6 +33,7 @@ WINE_1.0
wine_get_es;
wine_get_fs;
wine_get_gs;
@ -234,7 +234,7 @@ index 7cb2918..72ffed8 100644
wine_get_sortkey;
wine_get_ss;
diff --git a/loader/main.c b/loader/main.c
index f662912..a2dc40c 100644
index f6629128de1..a2dc40c51cc 100644
--- a/loader/main.c
+++ b/loader/main.c
@@ -36,6 +36,12 @@
@ -309,5 +309,5 @@ index f662912..a2dc40c 100644
--
1.9.1
2.17.1

View File

@ -1,4 +1,4 @@
From 657fcdbe239c1c1b37414acb82df75a27f643f38 Mon Sep 17 00:00:00 2001
From 0b6fc918564f580a9d62f14d76da83349075574f Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Fri, 4 Dec 2015 09:22:35 +1100
Subject: [PATCH] d3dx9_36: Support NULL terminated strings in
@ -7,14 +7,14 @@ Subject: [PATCH] d3dx9_36: Support NULL terminated strings in
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/d3dx9_36/font.c | 10 ++++++++--
dlls/d3dx9_36/tests/core.c | 44 ++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 52 insertions(+), 2 deletions(-)
dlls/d3dx9_36/tests/core.c | 1 -
2 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/dlls/d3dx9_36/font.c b/dlls/d3dx9_36/font.c
index 921dada..518a9dc 100644
index ad1eb2383e4..83fec560fc5 100644
--- a/dlls/d3dx9_36/font.c
+++ b/dlls/d3dx9_36/font.c
@@ -213,9 +213,12 @@ static INT WINAPI ID3DXFontImpl_DrawTextA(ID3DXFont *iface, ID3DXSprite *sprite,
@@ -210,9 +210,12 @@ static INT WINAPI ID3DXFontImpl_DrawTextA(ID3DXFont *iface, ID3DXSprite *sprite,
TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
iface, sprite, debugstr_a(string), count, wine_dbgstr_rect(rect), format, color);
@ -28,7 +28,7 @@ index 921dada..518a9dc 100644
countW = MultiByteToWideChar(CP_ACP, 0, string, count, NULL, 0);
stringW = HeapAlloc(GetProcessHeap(), 0, countW * sizeof(WCHAR));
if (stringW)
@@ -238,9 +241,12 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
@@ -235,9 +238,12 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
iface, sprite, debugstr_w(string), count, wine_dbgstr_rect(rect), format, color);
@ -42,68 +42,6 @@ index 921dada..518a9dc 100644
/* Strip terminating NULL characters */
while (count > 0 && !string[count-1])
count--;
diff --git a/dlls/d3dx9_36/tests/core.c b/dlls/d3dx9_36/tests/core.c
index 91e458b..b95c23f 100644
--- a/dlls/d3dx9_36/tests/core.c
+++ b/dlls/d3dx9_36/tests/core.c
@@ -306,6 +306,7 @@ static void test_ID3DXSprite(IDirect3DDevice9 *device)
static void test_ID3DXFont(IDirect3DDevice9 *device)
{
static const WCHAR testW[] = {'t','e','s','t',0};
+ static const char testA[] = "test";
static const struct
{
int font_height;
@@ -637,6 +638,49 @@ static void test_ID3DXFont(IDirect3DDevice9 *device)
ID3DXFont_Release(font);
}
+
+ /* ID3DXFont_DrawTextA, ID3DXFont_DrawTextW */
+ hr = D3DXCreateFontA(device, 12, 0, FW_DONTCARE, 0, FALSE, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH, "Arial", &font);
+ if (SUCCEEDED(hr)) {
+ RECT rect;
+ int height;
+
+ SetRect(&rect, 10, 10, 200, 200);
+
+ height = ID3DXFont_DrawTextA(font, NULL, testA, -2, &rect, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextA(font, NULL, testA, -1, &rect, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextA(font, NULL, testA, 0, &rect, 0, 0xFF00FF);
+ ok(height == 0, "DrawTextA returned %d, expected 0.\n", height);
+
+ height = ID3DXFont_DrawTextA(font, NULL, testA, 1, &rect, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextA(font, NULL, testA, 2, &rect, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+
+if (0) { /* Causes a lockup on windows 7. */
+ height = ID3DXFont_DrawTextW(font, NULL, testW, -2, &rect, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextW returned %d, expected 12.\n", height);
+}
+
+ height = ID3DXFont_DrawTextW(font, NULL, testW, -1, &rect, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextW returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextW(font, NULL, testW, 0, &rect, 0, 0xFF00FF);
+ ok(height == 0, "DrawTextW returned %d, expected 0.\n", height);
+
+ height = ID3DXFont_DrawTextW(font, NULL, testW, 1, &rect, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextW returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextW(font, NULL, testW, 2, &rect, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextW returned %d, expected 12.\n", height);
+
+ ID3DXFont_Release(font);
+ }
}
static void test_D3DXCreateRenderToSurface(IDirect3DDevice9 *device)
--
1.9.1
2.17.1

View File

@ -1,19 +1,18 @@
From 5b46372b7cc36f07d61bce63d5e3ae8aa766aa5a Mon Sep 17 00:00:00 2001
From ccf7cfe0cd7cbaa15ee34b4390dd6c30cf7e84ec Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Sat, 5 Dec 2015 15:31:06 +1100
Subject: d3dx9_36: ID3DXFont_DrawText calc_rect can be null
Subject: [PATCH] d3dx9_36: ID3DXFont_DrawText calc_rect can be null
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
dlls/d3dx9_36/font.c | 8 ++++++--
dlls/d3dx9_36/tests/core.c | 18 ++++++++++++++++++
2 files changed, 24 insertions(+), 2 deletions(-)
dlls/d3dx9_36/font.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/dlls/d3dx9_36/font.c b/dlls/d3dx9_36/font.c
index 63aa828..2262db9 100644
index 83fec560fc5..f5c704ebabb 100644
--- a/dlls/d3dx9_36/font.c
+++ b/dlls/d3dx9_36/font.c
@@ -236,7 +236,7 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
@@ -232,7 +232,7 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
const WCHAR *string, INT count, RECT *rect, DWORD format, D3DCOLOR color)
{
struct d3dx_font *This = impl_from_ID3DXFont(iface);
@ -22,7 +21,7 @@ index 63aa828..2262db9 100644
INT height;
TRACE("iface %p, sprite %p, string %s, count %d, rect %s, format %#x, color 0x%08x\n",
@@ -252,11 +252,15 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
@@ -248,11 +248,15 @@ static INT WINAPI ID3DXFontImpl_DrawTextW(ID3DXFont *iface, ID3DXSprite *sprite,
while (count > 0 && !string[count-1])
count--;
@ -39,42 +38,6 @@ index 63aa828..2262db9 100644
return height;
}
diff --git a/dlls/d3dx9_36/tests/core.c b/dlls/d3dx9_36/tests/core.c
index c931260..1cf0db6 100644
--- a/dlls/d3dx9_36/tests/core.c
+++ b/dlls/d3dx9_36/tests/core.c
@@ -616,6 +616,15 @@ static void test_ID3DXFont(IDirect3DDevice9 *device)
height = ID3DXFont_DrawTextA(font, NULL, testA, 2, &rect, 0, 0xFF00FF);
ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+ height = ID3DXFont_DrawTextA(font, NULL, testA, -1, NULL, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextA(font, NULL, testA, -1, NULL, DT_CALCRECT, 0xFF00FF);
+ ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextA(font, NULL, NULL, -1, NULL, 0, 0xFF00FF);
+ ok(height == 0, "DrawTextA returned %d, expected 0.\n", height);
+
if (0) { /* Causes a lockup on windows 7. */
height = ID3DXFont_DrawTextW(font, NULL, testW, -2, &rect, 0, 0xFF00FF);
ok(height == 12, "DrawTextW returned %d, expected 12.\n", height);
@@ -633,6 +642,15 @@ if (0) { /* Causes a lockup on windows 7. */
height = ID3DXFont_DrawTextW(font, NULL, testW, 2, &rect, 0, 0xFF00FF);
ok(height == 12, "DrawTextW returned %d, expected 12.\n", height);
+ height = ID3DXFont_DrawTextW(font, NULL, testW, -1, NULL, 0, 0xFF00FF);
+ ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextW(font, NULL, testW, -1, NULL, DT_CALCRECT, 0xFF00FF);
+ ok(height == 12, "DrawTextA returned %d, expected 12.\n", height);
+
+ height = ID3DXFont_DrawTextW(font, NULL, NULL, -1, NULL, 0, 0xFF00FF);
+ ok(height == 0, "DrawTextA returned %d, expected 0.\n", height);
+
ID3DXFont_Release(font);
}
}
--
2.6.2
2.17.1

View File

@ -1,4 +1,4 @@
From dcbf5bcf5fc813040532be9a4adc1999b74c189d Mon Sep 17 00:00:00 2001
From 76d0bfce8f6fec167e44afefc63dbbf4e52beda2 Mon Sep 17 00:00:00 2001
From: Paul Gofman <gofmanp@gmail.com>
Date: Tue, 14 Jan 2020 21:28:57 +0300
Subject: [PATCH] libs/wine: Add functions for managing free area list.
@ -10,10 +10,10 @@ Subject: [PATCH] libs/wine: Add functions for managing free area list.
3 files changed, 67 insertions(+), 17 deletions(-)
diff --git a/include/wine/library.h b/include/wine/library.h
index c141d96392..3e10bb4dee 100644
index 557cec20cf8..46d65328a91 100644
--- a/include/wine/library.h
+++ b/include/wine/library.h
@@ -89,6 +89,11 @@ extern int wine_mmap_is_in_reserved_area( void *addr, size_t size );
@@ -79,6 +79,11 @@ extern int wine_mmap_is_in_reserved_area( void *addr, size_t size );
extern int wine_mmap_enum_reserved_areas( int (*enum_func)(void *base, size_t size, void *arg),
void *arg, int top_down );
@ -26,7 +26,7 @@ index c141d96392..3e10bb4dee 100644
/* LDT management */
diff --git a/libs/wine/mmap.c b/libs/wine/mmap.c
index f2b5adc1d2..baa466c776 100644
index f2b5adc1d29..baa466c7766 100644
--- a/libs/wine/mmap.c
+++ b/libs/wine/mmap.c
@@ -52,7 +52,9 @@ struct reserved_area
@ -240,10 +240,10 @@ index f2b5adc1d2..baa466c776 100644
+ return wine_mmap_enum_areas(&free_areas_list, enum_func, arg, top_down);
+}
diff --git a/libs/wine/wine.map b/libs/wine/wine.map
index 72ffed80c0..448ab98572 100644
index 8e3382168d5..8d367d7b756 100644
--- a/libs/wine/wine.map
+++ b/libs/wine/wine.map
@@ -112,6 +112,10 @@ WINE_1.0
@@ -59,6 +59,10 @@ WINE_1.0
wine_mmap_enum_reserved_areas;
wine_mmap_is_in_reserved_area;
wine_mmap_remove_reserved_area;
@ -251,9 +251,9 @@ index 72ffed80c0..448ab98572 100644
+ wine_mmap_enum_free_areas;
+ wine_mmap_is_in_free_area;
+ wine_mmap_remove_free_area;
wine_pthread_get_functions;
wine_pthread_set_functions;
wine_set_fs;
wine_set_gs;
wine_utf8_mbstowcs;
--
2.24.1
2.17.1

View File

@ -52,7 +52,7 @@ usage()
# Get the upstream commit sha
upstream_commit()
{
echo "4588f10f8d3895624a8a2087f2e5c3c1b51e576f"
echo "1bb953c6766c9cc4372ca23a7c5b7de101324218"
}
# Show version information