winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
April 2020
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
1016 discussions
Start a n
N
ew thread
Francois Gouget : adsldp: Fix the spelling of some FIXME() messages.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: 0be09af819470791ba4cc0742549f1901e1440ab URL:
https://source.winehq.org/git/wine.git/?a=commit;h=0be09af819470791ba4cc074…
Author: Francois Gouget <fgouget(a)free.fr> Date: Tue Apr 14 16:57:41 2020 +0200 adsldp: Fix the spelling of some FIXME() messages. Signed-off-by: Francois Gouget <fgouget(a)free.fr> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/adsldp/adsldp.c | 4 ++-- dlls/adsldp/schema.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dlls/adsldp/adsldp.c b/dlls/adsldp/adsldp.c index dce462d685..c2f7ca8023 100644 --- a/dlls/adsldp/adsldp.c +++ b/dlls/adsldp/adsldp.c @@ -1147,7 +1147,7 @@ static HRESULT WINAPI search_SetSearchPreference(IDirectorySearch *iface, PADS_S case ADS_SEARCHPREF_SEARCH_SCOPE: if (prefs[i].vValue.dwType != ADSTYPE_INTEGER) { - FIXME("ADS_SEARCHPREF_SEACH_SCOPE: not supportd dwType %d\n", prefs[i].vValue.dwType); + FIXME("ADS_SEARCHPREF_SEACH_SCOPE: not supported dwType %d\n", prefs[i].vValue.dwType); prefs[i].dwStatus = ADS_STATUS_INVALID_SEARCHPREFVALUE; break; } @@ -1178,7 +1178,7 @@ static HRESULT WINAPI search_SetSearchPreference(IDirectorySearch *iface, PADS_S if (prefs[i].vValue.dwType != ADSTYPE_INTEGER) { - FIXME("ADS_SEARCHPREF_SECURITY_MASK: not supportd dwType %d\n", prefs[i].vValue.dwType); + FIXME("ADS_SEARCHPREF_SECURITY_MASK: not supported dwType %d\n", prefs[i].vValue.dwType); prefs[i].dwStatus = ADS_STATUS_INVALID_SEARCHPREFVALUE; break; } diff --git a/dlls/adsldp/schema.c b/dlls/adsldp/schema.c index 63c95bdae6..c8bcf3de66 100644 --- a/dlls/adsldp/schema.c +++ b/dlls/adsldp/schema.c @@ -227,7 +227,7 @@ static WCHAR *parse_name(WCHAR **str, ULONG *name_count) if (*p != '\'') { - FIXME("not suported NAME start at %s\n", debugstr_w(p)); + FIXME("not supported NAME start at %s\n", debugstr_w(p)); return NULL; }
1
0
0
0
Francois Gouget : dbghelp: Fix the spelling of a comment.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: ab4665f4ae3c67317e21d42868cae0af72ffcb7a URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ab4665f4ae3c67317e21d428…
Author: Francois Gouget <fgouget(a)free.fr> Date: Tue Apr 14 16:57:21 2020 +0200 dbghelp: Fix the spelling of a comment. Signed-off-by: Francois Gouget <fgouget(a)free.fr> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dbghelp/elf_module.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/dbghelp/elf_module.c b/dlls/dbghelp/elf_module.c index ab2a693eca..00e5c12c2e 100644 --- a/dlls/dbghelp/elf_module.c +++ b/dlls/dbghelp/elf_module.c @@ -105,7 +105,7 @@ struct elf_module_info #define ELF_SHT_FINI_ARRAY 15 /* Array of destructors */ #define ELF_SHT_PREINIT_ARRAY 16 /* Array of pre-constructors */ #define ELF_SHT_GROUP 17 /* Section group */ -#define ELF_SHT_SYMTAB_SHNDX 18 /* Extended section indeces */ +#define ELF_SHT_SYMTAB_SHNDX 18 /* Extended section indices */ #define ELF_SHT_NUM 19 /* Number of defined types. */ /* Legal values for ST_TYPE subfield of st_info (symbol type). */
1
0
0
0
Serge Gautherie : winapi_test: Do not multiply type size when it is undefined, in _refresh().
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: 3462153a05197e4951ed6b65195829ed9cea980e URL:
https://source.winehq.org/git/wine.git/?a=commit;h=3462153a05197e4951ed6b65…
Author: Serge Gautherie <winehq-git_serge_180711(a)gautherie.fr> Date: Tue Apr 14 11:47:23 2020 +0200 winapi_test: Do not multiply type size when it is undefined, in _refresh(). Signed-off-by: Serge Gautherie <winehq-git_serge_180711(a)gautherie.fr> Signed-off-by: Francois Gouget <fgouget(a)free.fr> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- tools/winapi/c_type.pm | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tools/winapi/c_type.pm b/tools/winapi/c_type.pm index b00cf81894..c6aeb6a912 100644 --- a/tools/winapi/c_type.pm +++ b/tools/winapi/c_type.pm @@ -239,8 +239,14 @@ sub _refresh($) } else { - print STDERR "$type_name -> type_size=undef, count=$count\n" if (!defined $type_size); - $type_size *= int($count); + if (!defined $type_size) + { + print STDERR "$type_name -> type_size=undef, count=$count\n"; + } + else + { + $type_size *= int($count); + } } } if ($bitfield_size != 0)
1
0
0
0
Jeff Smith : gdiplus: Check that GdipAddPathLine2 is passed at least one point.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: 93a5ce24453e12cde5d3b04cf6e300e74439c78e URL:
https://source.winehq.org/git/wine.git/?a=commit;h=93a5ce24453e12cde5d3b04c…
Author: Jeff Smith <whydoubt(a)gmail.com> Date: Mon Apr 13 22:50:52 2020 -0500 gdiplus: Check that GdipAddPathLine2 is passed at least one point. Signed-off-by: Jeff Smith <whydoubt(a)gmail.com> Signed-off-by: Vincent Povirk <vincent(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/gdiplus/graphicspath.c | 2 +- dlls/gdiplus/tests/graphicspath.c | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/dlls/gdiplus/graphicspath.c b/dlls/gdiplus/graphicspath.c index 2b191dd30d..4d5a73588f 100644 --- a/dlls/gdiplus/graphicspath.c +++ b/dlls/gdiplus/graphicspath.c @@ -627,7 +627,7 @@ GpStatus WINGDIPAPI GdipAddPathLine2(GpPath *path, GDIPCONST GpPointF *points, TRACE("(%p, %p, %d)\n", path, points, count); - if(!path || !points) + if(!path || !points || count < 1) return InvalidParameter; if(!lengthen_path(path, count)) diff --git a/dlls/gdiplus/tests/graphicspath.c b/dlls/gdiplus/tests/graphicspath.c index 0c5297249a..7670a6c41f 100644 --- a/dlls/gdiplus/tests/graphicspath.c +++ b/dlls/gdiplus/tests/graphicspath.c @@ -308,6 +308,16 @@ static void test_line2(void) } GdipCreatePath(FillModeAlternate, &path); + + status = GdipAddPathLine2(NULL, line2_points, 2); + expect(InvalidParameter, status); + status = GdipAddPathLine2(path, NULL, 2); + expect(InvalidParameter, status); + status = GdipAddPathLine2(path, line2_points, 0); + expect(InvalidParameter, status); + status = GdipAddPathLine2(path, line2_points, -1); + expect(InvalidParameter, status); + status = GdipAddPathLine2(path, line2_points, 3); expect(Ok, status); status = GdipAddPathLine2(path, &(line2_points[3]), 3);
1
0
0
0
Jeff Smith : gdiplus: Clear new multi-point paths that end with Start.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: efd5f670bdac46c788efe566d4e28c3012c8874a URL:
https://source.winehq.org/git/wine.git/?a=commit;h=efd5f670bdac46c788efe566…
Author: Jeff Smith <whydoubt(a)gmail.com> Date: Mon Apr 13 22:50:51 2020 -0500 gdiplus: Clear new multi-point paths that end with Start. Signed-off-by: Jeff Smith <whydoubt(a)gmail.com> Signed-off-by: Vincent Povirk <vincent(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/gdiplus/graphicspath.c | 3 +++ dlls/gdiplus/tests/graphicspath.c | 13 ++++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/dlls/gdiplus/graphicspath.c b/dlls/gdiplus/graphicspath.c index df6a32d22d..2b191dd30d 100644 --- a/dlls/gdiplus/graphicspath.c +++ b/dlls/gdiplus/graphicspath.c @@ -1228,6 +1228,9 @@ GpStatus WINGDIPAPI GdipCreatePath2(GDIPCONST GpPointF* points, *path = heap_alloc_zero(sizeof(GpPath)); if(!*path) return OutOfMemory; + if(count > 1 && (types[count-1] & PathPointTypePathTypeMask) == PathPointTypeStart) + count = 0; + for(i = 1; i < count; i++) { if((types[i] & PathPointTypePathTypeMask) == PathPointTypeBezier) { if(i+2 < count && diff --git a/dlls/gdiplus/tests/graphicspath.c b/dlls/gdiplus/tests/graphicspath.c index 1b3a9a161f..0c5297249a 100644 --- a/dlls/gdiplus/tests/graphicspath.c +++ b/dlls/gdiplus/tests/graphicspath.c @@ -181,8 +181,8 @@ static void test_createpath2(void) GpPathData data; INT i, count, expect_count; - PointF test_line_points[] = {{1.0,1.0}, {2.0,1.0}}; - BYTE test_line_types[] = {PathPointTypeStart, PathPointTypeLine}; + PointF test_line_points[] = {{1.0,1.0}, {2.0,1.0}, {2.0,2.0}}; + BYTE test_line_types[] = {PathPointTypeStart, PathPointTypeLine, PathPointTypeStart}; PointF test_bez_points[] = {{1.0,1.0}, {2.0,1.0}, {3.0,1.0}, {4.0,1.0}, {5.0,1.0}, {6.0,1.0}, {7.0,1.0}}; @@ -235,8 +235,15 @@ static void test_createpath2(void) status = GdipCreatePath2(test_line_points, test_line_types, 2, FillModeAlternate, NULL); expect(InvalidParameter, status); + /* Multi-point paths should not end with Start */ + status = GdipCreatePath2(test_line_points, test_line_types, 3, FillModeAlternate, &path); + expect(Ok, status); + status = GdipGetPointCount(path, &count); + expect(Ok, status); + expect(0, count); + GdipDeletePath(path); + /* Zero-length line points do not get altered */ - path = NULL; test_line_points[1].X = test_line_points[0].X; test_line_points[1].Y = test_line_points[0].Y; status = GdipCreatePath2(test_line_points, test_line_types, 2, FillModeAlternate, &path);
1
0
0
0
Alexandre Julliard : ntdll: Always use the loaded path as builtin module file name.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: a55feef63a751a04b9f19011d232f3456502d655 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a55feef63a751a04b9f19011…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Tue Apr 14 21:58:56 2020 +0200 ntdll: Always use the loaded path as builtin module file name. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/loader.c | 95 +++++++++++++++-------------------------------------- 1 file changed, 26 insertions(+), 69 deletions(-) diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c index 524eab7460..9329dd2a9b 100644 --- a/dlls/ntdll/loader.c +++ b/dlls/ntdll/loader.c @@ -1749,50 +1749,6 @@ NTSTATUS WINAPI LdrGetProcedureAddress(HMODULE module, const ANSI_STRING *name, } -/*********************************************************************** - * get_builtin_fullname - * - * Build the full pathname for a builtin dll. - */ -static BOOL get_builtin_fullname( UNICODE_STRING *nt_name, const UNICODE_STRING *path, - const char *filename ) -{ - static const WCHAR nt_prefixW[] = {'\\','?','?','\\',0}; - static const WCHAR soW[] = {'.','s','o',0}; - WCHAR *p, *fullname, filenameW[256]; - size_t len = strlen(filename); - - if (len >= ARRAY_SIZE(filenameW)) return FALSE; - ascii_to_unicode( filenameW, filename, len + 1 ); - - /* check if path can correspond to the dll we have */ - if (path && (p = wcsrchr( path->Buffer, '\\' ))) - { - p++; - if (!wcsnicmp( p, filenameW, len ) && (!p[len] || !wcsicmp( p + len, soW ))) - { - /* the filename matches, use path as the full path */ - len += p - path->Buffer; - if (!(fullname = RtlAllocateHeap( GetProcessHeap(), 0, (len + 1) * sizeof(WCHAR) ))) - return FALSE; - memcpy( fullname, path->Buffer, len * sizeof(WCHAR) ); - fullname[len] = 0; - goto done; - } - } - - if (!(fullname = RtlAllocateHeap( GetProcessHeap(), 0, - (wcslen(system_dir) + len + 5) * sizeof(WCHAR) ))) - return FALSE; - wcscpy( fullname, nt_prefixW ); - wcscat( fullname, system_dir ); - wcscat( fullname, filenameW ); -done: - RtlInitUnicodeString( nt_name, fullname ); - return TRUE; -} - - /************************************************************************* * is_16bit_builtin */ @@ -1819,17 +1775,16 @@ static void load_builtin_callback( void *module, const char *filename ) static const WCHAR emptyW[1]; IMAGE_NT_HEADERS *nt; WINE_MODREF *wm; - UNICODE_STRING nt_name; const WCHAR *load_path; if (!module) { - ERR("could not map image for %s\n", filename ? filename : "main exe" ); + ERR("could not map image for %s\n", debugstr_us(builtin_load_info->filename) ); return; } if (!(nt = RtlImageNtHeader( module ))) { - ERR( "bad module for %s\n", filename ? filename : "main exe" ); + ERR( "bad module for %s\n", debugstr_us(builtin_load_info->filename) ); builtin_load_info->status = STATUS_INVALID_IMAGE_FORMAT; return; } @@ -1838,18 +1793,10 @@ static void load_builtin_callback( void *module, const char *filename ) /* create the MODREF */ - if (!get_builtin_fullname( &nt_name, builtin_load_info->filename, filename )) - { - ERR( "can't load %s\n", filename ); - builtin_load_info->status = STATUS_NO_MEMORY; - return; - } - - wm = alloc_module( module, &nt_name, TRUE ); - RtlFreeUnicodeString( &nt_name ); + wm = alloc_module( module, builtin_load_info->filename, TRUE ); if (!wm) { - ERR( "can't load %s\n", filename ); + ERR( "can't load %s\n", debugstr_us(builtin_load_info->filename) ); builtin_load_info->status = STATUS_NO_MEMORY; return; } @@ -1875,7 +1822,7 @@ static void load_builtin_callback( void *module, const char *filename ) } builtin_load_info->wm = wm; - TRACE( "loaded %s %p %p\n", filename, wm, module ); + TRACE( "loaded %s %p %p\n", debugstr_us(builtin_load_info->filename), wm, module ); /* send the DLL load event */ @@ -2605,26 +2552,31 @@ done: static NTSTATUS load_so_dll( LPCWSTR load_path, const UNICODE_STRING *nt_name, const char *so_name, WINE_MODREF** pwm ) { + static const WCHAR soW[] = {'.','s','o',0}; + DWORD len; void *handle; struct builtin_load_info info, *prev_info; ANSI_STRING unix_name; + UNICODE_STRING win_name = *nt_name; - if (so_name) - { - TRACE( "loading %s from so lib %s\n", debugstr_us(nt_name), debugstr_a(so_name) ); - unix_name.Buffer = NULL; - } - else + unix_name.Buffer = NULL; + info.load_path = load_path; + info.filename = &win_name; + info.status = STATUS_SUCCESS; + info.wm = NULL; + + if (!so_name) { - TRACE( "loading %s as so lib\n", debugstr_us(nt_name) ); if (wine_nt_to_unix_file_name( nt_name, &unix_name, FILE_OPEN, FALSE )) return STATUS_DLL_NOT_FOUND; + + /* remove .so extension from Windows name */ + len = nt_name->Length / sizeof(WCHAR); + if (len > 3 && !wcsicmp( nt_name->Buffer + len - 3, soW )) win_name.Length -= 3 * sizeof(WCHAR); } - info.load_path = load_path; - info.filename = nt_name; - info.status = STATUS_SUCCESS; - info.wm = NULL; + TRACE( "loading %s from so lib %s\n", debugstr_us(&win_name), + debugstr_a( so_name ? so_name : unix_name.Buffer )); prev_info = builtin_load_info; builtin_load_info = &info; @@ -4254,6 +4206,9 @@ BOOL WINAPI DllMain( HINSTANCE inst, DWORD reason, LPVOID reserved ) */ void __wine_process_init(void) { + static const WCHAR ntdllW[] = {'\\','?','?','\\','C',':','\\','w','i','n','d','o','w','s','\\', + 's','y','s','t','e','m','3','2','\\', + 'n','t','d','l','l','.','d','l','l',0}; static const WCHAR kernel32W[] = {'\\','?','?','\\','C',':','\\','w','i','n','d','o','w','s','\\', 's','y','s','t','e','m','3','2','\\', 'k','e','r','n','e','l','3','2','.','d','l','l',0}; @@ -4289,6 +4244,8 @@ void __wine_process_init(void) version_init(); /* setup the load callback and create ntdll modref */ + RtlInitUnicodeString( &nt_name, ntdllW ); + default_load_info.filename = &nt_name; wine_dll_set_callback( load_builtin_callback ); RtlInitUnicodeString( &nt_name, kernel32W );
1
0
0
0
Alexandre Julliard : ntdll: Allow the module file name to not be null-terminated.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: 19c48204bb0aa3dadde1247a66b69d9cd51b7e03 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=19c48204bb0aa3dadde1247a…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Tue Apr 14 21:58:23 2020 +0200 ntdll: Allow the module file name to not be null-terminated. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/loader.c | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c index 2be0cde537..524eab7460 100644 --- a/dlls/ntdll/loader.c +++ b/dlls/ntdll/loader.c @@ -1174,6 +1174,7 @@ static NTSTATUS fixup_imports( WINE_MODREF *wm, LPCWSTR load_path ) */ static WINE_MODREF *alloc_module( HMODULE hModule, const UNICODE_STRING *nt_name, BOOL builtin ) { + WCHAR *buffer; WINE_MODREF *wm; const WCHAR *p; const IMAGE_NT_HEADERS *nt = RtlImageNtHeader(hModule); @@ -1186,9 +1187,16 @@ static WINE_MODREF *alloc_module( HMODULE hModule, const UNICODE_STRING *nt_name wm->ldr.TlsIndex = -1; wm->ldr.LoadCount = 1; - RtlCreateUnicodeString( &wm->ldr.FullDllName, nt_name->Buffer + 4 /* \??\ prefix */ ); - if ((p = wcsrchr( wm->ldr.FullDllName.Buffer, '\\' ))) p++; - else p = wm->ldr.FullDllName.Buffer; + if (!(buffer = RtlAllocateHeap( GetProcessHeap(), 0, nt_name->Length - 3 * sizeof(WCHAR) ))) + { + RtlFreeHeap( GetProcessHeap(), 0, wm ); + return NULL; + } + memcpy( buffer, nt_name->Buffer + 4 /* \??\ prefix */, nt_name->Length - 4 * sizeof(WCHAR) ); + buffer[nt_name->Length/sizeof(WCHAR) - 4] = 0; + if ((p = wcsrchr( buffer, '\\' ))) p++; + else p = buffer; + RtlInitUnicodeString( &wm->ldr.FullDllName, buffer ); RtlInitUnicodeString( &wm->ldr.BaseDllName, p ); if (!is_dll_native_subsystem( &wm->ldr, nt, p ))
1
0
0
0
Alexandre Julliard : ntdll: Don't call entry point for the main process so that we don't need to check the dll flag.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: fd7992972b252ed262d33ef604e9e1235d2108c5 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=fd7992972b252ed262d33ef6…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Tue Apr 14 12:55:38 2020 +0200 ntdll: Don't call entry point for the main process so that we don't need to check the dll flag. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=48817
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/loader.c | 34 ++++++++++++++++++++++++---------- 1 file changed, 24 insertions(+), 10 deletions(-) diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c index 79165c2dac..2be0cde537 100644 --- a/dlls/ntdll/loader.c +++ b/dlls/ntdll/loader.c @@ -1191,7 +1191,7 @@ static WINE_MODREF *alloc_module( HMODULE hModule, const UNICODE_STRING *nt_name else p = wm->ldr.FullDllName.Buffer; RtlInitUnicodeString( &wm->ldr.BaseDllName, p ); - if (!(nt->FileHeader.Characteristics & IMAGE_FILE_DLL) || !is_dll_native_subsystem( &wm->ldr, nt, p )) + if (!is_dll_native_subsystem( &wm->ldr, nt, p )) { if (nt->FileHeader.Characteristics & IMAGE_FILE_DLL) wm->ldr.Flags |= LDR_IMAGE_IS_DLL; @@ -1311,7 +1311,7 @@ static NTSTATUS MODULE_InitDLL( WINE_MODREF *wm, UINT reason, LPVOID lpReserved if (wm->ldr.Flags & LDR_DONT_RESOLVE_REFS) return STATUS_SUCCESS; if (wm->ldr.TlsIndex != -1) call_tls_callbacks( wm->ldr.BaseAddress, reason ); - if (!entry || !(wm->ldr.Flags & LDR_IMAGE_IS_DLL)) return STATUS_SUCCESS; + if (!entry) return STATUS_SUCCESS; if (TRACE_ON(relay)) { @@ -1463,6 +1463,7 @@ static void attach_implicitly_loaded_dlls( LPVOID reserved ) { LDR_MODULE *mod = CONTAINING_RECORD(entry, LDR_MODULE, InLoadOrderModuleList); + if (!(mod->Flags & LDR_IMAGE_IS_DLL)) continue; if (mod->Flags & (LDR_LOAD_IN_PROGRESS | LDR_PROCESS_ATTACHED)) continue; TRACE( "found implicitly loaded %s, attaching to it\n", debugstr_w(mod->BaseDllName.Buffer)); @@ -3740,7 +3741,10 @@ PIMAGE_NT_HEADERS WINAPI RtlImageNtHeader(HMODULE hModule) void WINAPI LdrInitializeThunk( CONTEXT *context, void **entry, ULONG_PTR unknown3, ULONG_PTR unknown4 ) { static const LARGE_INTEGER zero; + static int attach_done; + int i; NTSTATUS status; + ULONG_PTR cookie; WINE_MODREF *wm; LPCWSTR load_path = NtCurrentTeb()->Peb->ProcessParameters->DllPath.Buffer; @@ -3774,25 +3778,35 @@ void WINAPI LdrInitializeThunk( CONTEXT *context, void **entry, ULONG_PTR unknow InsertHeadList( &tls_links, &NtCurrentTeb()->TlsLinks ); RtlReleasePebLock(); - if (!(wm->ldr.Flags & LDR_PROCESS_ATTACHED)) /* first time around */ + if (!attach_done) /* first time around */ { + attach_done = 1; if ((status = alloc_thread_tls()) != STATUS_SUCCESS) { ERR( "TLS init failed when loading %s, status %x\n", debugstr_w(NtCurrentTeb()->Peb->ProcessParameters->ImagePathName.Buffer), status ); NtTerminateProcess( GetCurrentProcess(), status ); } - if ((status = process_attach( wm, context )) != STATUS_SUCCESS) + wm->ldr.LoadCount = -1; + if (wm->ldr.ActivationContext) + RtlActivateActivationContext( 0, wm->ldr.ActivationContext, &cookie ); + + for (i = 0; i < wm->nDeps; i++) { - if (last_failed_modref) - ERR( "%s failed to initialize, aborting\n", - debugstr_w(last_failed_modref->ldr.BaseDllName.Buffer) + 1 ); - ERR( "Initializing dlls for %s failed, status %x\n", - debugstr_w(NtCurrentTeb()->Peb->ProcessParameters->ImagePathName.Buffer), status ); - NtTerminateProcess( GetCurrentProcess(), status ); + if (!wm->deps[i]) continue; + if ((status = process_attach( wm->deps[i], context )) != STATUS_SUCCESS) + { + if (last_failed_modref) + ERR( "%s failed to initialize, aborting\n", + debugstr_w(last_failed_modref->ldr.BaseDllName.Buffer) + 1 ); + ERR( "Initializing dlls for %s failed, status %x\n", + debugstr_w(NtCurrentTeb()->Peb->ProcessParameters->ImagePathName.Buffer), status ); + NtTerminateProcess( GetCurrentProcess(), status ); + } } attach_implicitly_loaded_dlls( context ); virtual_release_address_space(); + if (wm->ldr.ActivationContext) RtlDeactivateActivationContext( 0, cookie ); } else {
1
0
0
0
Ziqing Hui : comctl32/imagelist: Add support for ILD_PRESERVEALPHA.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: 28c60b64c7cbc4ef891f972ea4f88e3fcf59ad3d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=28c60b64c7cbc4ef891f972e…
Author: Ziqing Hui <zhui(a)codeweavers.com> Date: Tue Apr 14 10:40:16 2020 +0800 comctl32/imagelist: Add support for ILD_PRESERVEALPHA. Signed-off-by: Ziqing Hui <zhui(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/comctl32/imagelist.c | 38 ++++++++++++++++++++++++-------------- dlls/comctl32/tests/imagelist.c | 2 +- 2 files changed, 25 insertions(+), 15 deletions(-) diff --git a/dlls/comctl32/imagelist.c b/dlls/comctl32/imagelist.c index 013ae42f88..a6d9c73c49 100644 --- a/dlls/comctl32/imagelist.c +++ b/dlls/comctl32/imagelist.c @@ -23,7 +23,7 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA * * TODO: - * - Add support for ILD_PRESERVEALPHA, ILD_SCALE, ILD_DPISCALE + * - Add support for ILD_SCALE, ILD_DPISCALE * - Add support for ILS_GLOW, ILS_SHADOW * - Thread-safe locking */ @@ -1234,17 +1234,23 @@ ImageList_DrawEx (HIMAGELIST himl, INT i, HDC hdc, INT x, INT y, static BOOL alpha_blend_image( HIMAGELIST himl, HDC dest_dc, int dest_x, int dest_y, - int src_x, int src_y, int cx, int cy, BLENDFUNCTION func, - UINT style, COLORREF blend_col, BOOL has_alpha, BOOL grayscale ) + int src_x, int src_y, int cx, int cy, UINT style, UINT state, + DWORD frame, COLORREF blend_col, BOOL has_alpha ) { BOOL ret = FALSE; HDC hdc; HBITMAP bmp = 0, mask = 0; BITMAPINFO *info; + BLENDFUNCTION func; void *bits, *mask_bits; unsigned int *ptr; int i, j; + func.BlendOp = AC_SRC_OVER; + func.BlendFlags = 0; + func.SourceConstantAlpha = 255; + func.AlphaFormat = AC_SRC_ALPHA; + if (!(hdc = CreateCompatibleDC( 0 ))) return FALSE; if (!(info = heap_alloc( FIELD_OFFSET( BITMAPINFO, bmiColors[256] )))) goto done; info->bmiHeader.biSize = sizeof(BITMAPINFOHEADER); @@ -1286,7 +1292,12 @@ static BOOL alpha_blend_image( HIMAGELIST himl, HDC dest_dc, int dest_x, int des } } - if (grayscale) + + if (state & ILS_ALPHA) + { + func.SourceConstantAlpha = (BYTE)frame; + } + else if (state & ILS_SATURATE) { for (i = 0, ptr = bits; i < cx * cy; i++, ptr++) { @@ -1297,6 +1308,12 @@ static BOOL alpha_blend_image( HIMAGELIST himl, HDC dest_dc, int dest_x, int des *ptr = (*ptr & 0xff000000)| (gray << 16) | (gray << 8) | gray; } } + else if (style & ILD_PRESERVEALPHA) + { + HBRUSH old_brush = SelectObject( dest_dc, GetStockObject(BLACK_BRUSH) ); + PatBlt( dest_dc, dest_x, dest_y, cx, cy, PATCOPY ); + SelectObject( dest_dc, old_brush ); + } if (has_alpha) /* we already have an alpha channel in this case */ { @@ -1430,7 +1447,6 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp) if (!bMask && (has_alpha || (fState & ILS_ALPHA) || (fState & ILS_SATURATE))) { COLORREF colour, blend_col = CLR_NONE; - BLENDFUNCTION func; if (bBlend) { @@ -1439,15 +1455,10 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp) else if (blend_col == CLR_NONE) blend_col = GetTextColor( pimldp->hdcDst ); } - func.BlendOp = AC_SRC_OVER; - func.BlendFlags = 0; - func.SourceConstantAlpha = (fState & ILS_ALPHA) ? pimldp->Frame : 255; - func.AlphaFormat = AC_SRC_ALPHA; - if (bIsTransparent) { bResult = alpha_blend_image( himl, pimldp->hdcDst, pimldp->x, pimldp->y, pt.x, pt.y, cx, cy, - func, fStyle, blend_col, has_alpha, fState & ILS_SATURATE ); + fStyle, fState, pimldp->Frame, blend_col, has_alpha ); goto end; } colour = pimldp->rgbBk; @@ -1456,8 +1467,8 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp) hOldBrush = SelectObject (hImageDC, CreateSolidBrush (colour)); PatBlt( hImageDC, 0, 0, cx, cy, PATCOPY ); - alpha_blend_image( himl, hImageDC, 0, 0, pt.x, pt.y, cx, cy, func, - fStyle, blend_col, has_alpha, fState & ILS_SATURATE ); + alpha_blend_image( himl, hImageDC, 0, 0, pt.x, pt.y, cx, cy, fStyle, fState, + pimldp->Frame, blend_col, has_alpha ); DeleteObject (SelectObject (hImageDC, hOldBrush)); bResult = BitBlt( pimldp->hdcDst, pimldp->x, pimldp->y, cx, cy, hImageDC, 0, 0, SRCCOPY ); goto end; @@ -1554,7 +1565,6 @@ ImageList_DrawIndirect (IMAGELISTDRAWPARAMS *pimldp) if (fState & ILS_GLOW) FIXME("ILS_GLOW: unimplemented!\n"); if (fState & ILS_SHADOW) FIXME("ILS_SHADOW: unimplemented!\n"); - if (fStyle & ILD_PRESERVEALPHA) FIXME("ILD_PRESERVEALPHA: unimplemented!\n"); if (fStyle & ILD_SCALE) FIXME("ILD_SCALE: unimplemented!\n"); if (fStyle & ILD_DPISCALE) FIXME("ILD_DPISCALE: unimplemented!\n"); diff --git a/dlls/comctl32/tests/imagelist.c b/dlls/comctl32/tests/imagelist.c index d3f12e1679..db18443f89 100644 --- a/dlls/comctl32/tests/imagelist.c +++ b/dlls/comctl32/tests/imagelist.c @@ -1600,7 +1600,7 @@ static void test_ImageList_DrawIndirect(void) check_ImageList_DrawIndirect_fStyle(hdcDst, himl, bits, iAlphaImage, ILD_MASK, 0xFFD3E5F7, __LINE__); check_ImageList_DrawIndirect_fStyle(hdcDst, himl, bits, iAlphaImage, ILD_IMAGE, 0xFFD3E5F7, __LINE__); - todo_wine check_ImageList_DrawIndirect_fStyle(hdcDst, himl, bits, iAlphaImage, ILD_PRESERVEALPHA, 0x895D6F81, __LINE__); + check_ImageList_DrawIndirect_fStyle(hdcDst, himl, bits, iAlphaImage, ILD_PRESERVEALPHA, 0x895D6F81, __LINE__); check_ImageList_DrawIndirect_broken(hdcDst, himl, bits, iAlphaImage, ILD_PRESERVEALPHA, ILS_ALPHA, 127, 0xFFE9F2FB, 0xFFAEB7C0, __LINE__); check_ImageList_DrawIndirect_broken(hdcDst, himl, bits, iAlphaImage, ILD_PRESERVEALPHA, ILS_SATURATE, 0, 0xFFAFAFAF, 0xFFF0F0F0, __LINE__);
1
0
0
0
Ziqing Hui : comctl32/tests: Add more tests for ILD_PRESERVEALPHA.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: a6bb675eb7b9c12020e0af93793442aaba967b1d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a6bb675eb7b9c12020e0af93…
Author: Ziqing Hui <zhui(a)codeweavers.com> Date: Tue Apr 14 10:39:50 2020 +0800 comctl32/tests: Add more tests for ILD_PRESERVEALPHA. Signed-off-by: Ziqing Hui <zhui(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/comctl32/tests/imagelist.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dlls/comctl32/tests/imagelist.c b/dlls/comctl32/tests/imagelist.c index 1c047e046c..d3f12e1679 100644 --- a/dlls/comctl32/tests/imagelist.c +++ b/dlls/comctl32/tests/imagelist.c @@ -1599,7 +1599,10 @@ static void test_ImageList_DrawIndirect(void) todo_wine check_ImageList_DrawIndirect_broken(hdcDst, himl, bits, iAlphaImage, ILD_BLEND50, ILS_NORMAL, 0, 0xFFE8F1FA, broken_value, __LINE__); check_ImageList_DrawIndirect_fStyle(hdcDst, himl, bits, iAlphaImage, ILD_MASK, 0xFFD3E5F7, __LINE__); check_ImageList_DrawIndirect_fStyle(hdcDst, himl, bits, iAlphaImage, ILD_IMAGE, 0xFFD3E5F7, __LINE__); + todo_wine check_ImageList_DrawIndirect_fStyle(hdcDst, himl, bits, iAlphaImage, ILD_PRESERVEALPHA, 0x895D6F81, __LINE__); + check_ImageList_DrawIndirect_broken(hdcDst, himl, bits, iAlphaImage, ILD_PRESERVEALPHA, ILS_ALPHA, 127, 0xFFE9F2FB, 0xFFAEB7C0, __LINE__); + check_ImageList_DrawIndirect_broken(hdcDst, himl, bits, iAlphaImage, ILD_PRESERVEALPHA, ILS_SATURATE, 0, 0xFFAFAFAF, 0xFFF0F0F0, __LINE__); check_ImageList_DrawIndirect_fStyle(hdcDst, himl, bits, iTransparentImage, ILD_NORMAL, 0xFFFFFFFF, __LINE__);
1
0
0
0
← Newer
1
...
60
61
62
63
64
65
66
...
102
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
Results per page:
10
25
50
100
200