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
December 2017
----- 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
450 discussions
Start a n
N
ew thread
Józef Kucia : ddraw: Cleanup ddraw_get_d3dcaps().
by Alexandre Julliard
04 Dec '17
04 Dec '17
Module: wine Branch: master Commit: d1f518975914e41ad03d717a88aff42f10a70cfe URL:
http://source.winehq.org/git/wine.git/?a=commit;h=d1f518975914e41ad03d717a8…
Author: Józef Kucia <jkucia(a)codeweavers.com> Date: Sat Dec 2 10:24:34 2017 +0100 ddraw: Cleanup ddraw_get_d3dcaps(). Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ddraw/ddraw.c | 21 ++++----------------- 1 file changed, 4 insertions(+), 17 deletions(-) diff --git a/dlls/ddraw/ddraw.c b/dlls/ddraw/ddraw.c index 5f90a75..d3e491c 100644 --- a/dlls/ddraw/ddraw.c +++ b/dlls/ddraw/ddraw.c @@ -1420,23 +1420,10 @@ HRESULT ddraw_get_d3dcaps(const struct ddraw *ddraw, D3DDEVICEDESC7 *caps) caps->dwMinTextureHeight = 1; /* Convert DWORDs safely to WORDs */ - if (wined3d_caps.MaxTextureBlendStages > 0xffff) - caps->wMaxTextureBlendStages = 0xffff; - else - caps->wMaxTextureBlendStages = (WORD)wined3d_caps.MaxTextureBlendStages; - if (wined3d_caps.MaxSimultaneousTextures > 0xffff) - caps->wMaxSimultaneousTextures = 0xffff; - else - caps->wMaxSimultaneousTextures = (WORD)wined3d_caps.MaxSimultaneousTextures; - - if (wined3d_caps.MaxUserClipPlanes > 0xffff) - caps->wMaxUserClipPlanes = 0xffff; - else - caps->wMaxUserClipPlanes = (WORD)wined3d_caps.MaxUserClipPlanes; - if (wined3d_caps.MaxVertexBlendMatrices > 0xffff) - caps->wMaxVertexBlendMatrices = 0xffff; - else - caps->wMaxVertexBlendMatrices = (WORD)wined3d_caps.MaxVertexBlendMatrices; + caps->wMaxTextureBlendStages = min(wined3d_caps.MaxTextureBlendStages, 0xffff); + caps->wMaxSimultaneousTextures = min(wined3d_caps.MaxSimultaneousTextures, 0xffff); + caps->wMaxUserClipPlanes = min(wined3d_caps.MaxUserClipPlanes, D3DMAXUSERCLIPPLANES); + caps->wMaxVertexBlendMatrices = min(wined3d_caps.MaxVertexBlendMatrices, 0xffff); caps->deviceGUID = IID_IDirect3DTnLHalDevice;
1
0
0
0
Zebediah Figura : shell32: Implement the Groups request for Progman DDE.
by Alexandre Julliard
04 Dec '17
04 Dec '17
Module: wine Branch: master Commit: 35d203622b7964ffbce9840067954980fa2ce9f0 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=35d203622b7964ffbce984006…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Fri Dec 1 20:52:51 2017 -0600 shell32: Implement the Groups request for Progman DDE. Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/shell32/dde.c | 81 +++++++++++++++++++++++++++++----------- dlls/shell32/tests/progman_dde.c | 53 ++++++++++++++++++++++++++ 2 files changed, 112 insertions(+), 22 deletions(-) diff --git a/dlls/shell32/dde.c b/dlls/shell32/dde.c index cfe5a05..365ce1c 100644 --- a/dlls/shell32/dde.c +++ b/dlls/shell32/dde.c @@ -79,29 +79,8 @@ static inline BOOL Dde_OnWildConnect(HSZ hszTopic, HSZ hszService) return FALSE; } -static inline HDDEDATA Dde_OnRequest(UINT uFmt, HCONV hconv, HSZ hszTopic, - HSZ hszItem) -{ - if (hszTopic == hszProgmanTopic && hszItem == hszGroups && uFmt == CF_TEXT) - { - static BYTE groups_data[] = "Accessories\r\nStartup\r\n"; - FIXME( "returning fake program groups list\n" ); - return DdeCreateDataHandle( dwDDEInst, groups_data, sizeof(groups_data), 0, hszGroups, uFmt, 0 ); - } - else if (hszTopic == hszProgmanTopic && hszItem == hszProgmanService && uFmt == CF_TEXT) - { - static BYTE groups_data[] = "\r\n"; - FIXME( "returning empty groups list\n" ); - /* This is a workaround for an application which expects some data - * and cannot handle NULL. */ - return DdeCreateDataHandle( dwDDEInst, groups_data, sizeof(groups_data), 0, hszProgmanService, uFmt, 0 ); - } - FIXME( "%u %p %s %s: stub\n", uFmt, hconv, debugstr_hsz(hszTopic), debugstr_hsz(hszItem) ); - return NULL; -} - /* Returned string must be freed by caller */ -static WCHAR *get_programs_path(WCHAR *name) +static WCHAR *get_programs_path(const WCHAR *name) { static const WCHAR slashW[] = {'/',0}; WCHAR *programs, *path; @@ -120,6 +99,64 @@ static WCHAR *get_programs_path(WCHAR *name) return path; } +static inline HDDEDATA Dde_OnRequest(UINT uFmt, HCONV hconv, HSZ hszTopic, + HSZ hszItem) +{ + if (hszTopic == hszProgmanTopic && hszItem == hszGroups && uFmt == CF_TEXT) + { + static const WCHAR asteriskW[] = {'*',0}; + static const WCHAR newlineW[] = {'\r','\n',0}; + static const WCHAR dotW[] = {'.',0}; + static const WCHAR dotdotW[] = {'.','.',0}; + WCHAR *programs; + WIN32_FIND_DATAW finddata; + HANDLE hfind; + int len = 1; + WCHAR *groups_data = HeapAlloc(GetProcessHeap(), 0, sizeof(WCHAR)); + char *groups_dataA; + HDDEDATA ret; + + groups_data[0] = 0; + programs = get_programs_path(asteriskW); + hfind = FindFirstFileW(programs, &finddata); + if (hfind) + { + do + { + if ((finddata.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) && + lstrcmpW(finddata.cFileName, dotW) && lstrcmpW(finddata.cFileName, dotdotW)) + { + len += lstrlenW(finddata.cFileName) + 2; + groups_data = HeapReAlloc(GetProcessHeap(), 0, groups_data, len * sizeof(WCHAR)); + lstrcatW(groups_data, finddata.cFileName); + lstrcatW(groups_data, newlineW); + } + } while (FindNextFileW(hfind, &finddata)); + FindClose(hfind); + } + + len = WideCharToMultiByte(CP_ACP, 0, groups_data, -1, NULL, 0, NULL, NULL); + groups_dataA = HeapAlloc(GetProcessHeap(), 0, len * sizeof(WCHAR)); + WideCharToMultiByte(CP_ACP, 0, groups_data, -1, groups_dataA, len, NULL, NULL); + ret = DdeCreateDataHandle(dwDDEInst, (BYTE *)groups_dataA, len, 0, hszGroups, uFmt, 0); + + HeapFree(GetProcessHeap(), 0, groups_dataA); + HeapFree(GetProcessHeap(), 0, groups_data); + HeapFree(GetProcessHeap(), 0, programs); + return ret; + } + else if (hszTopic == hszProgmanTopic && hszItem == hszProgmanService && uFmt == CF_TEXT) + { + static BYTE groups_data[] = "\r\n"; + FIXME( "returning empty groups list\n" ); + /* This is a workaround for an application which expects some data + * and cannot handle NULL. */ + return DdeCreateDataHandle( dwDDEInst, groups_data, sizeof(groups_data), 0, hszProgmanService, uFmt, 0 ); + } + FIXME( "%u %p %s %s: stub\n", uFmt, hconv, debugstr_hsz(hszTopic), debugstr_hsz(hszItem) ); + return NULL; +} + static DWORD PROGMAN_OnExecute(WCHAR *command, int argc, WCHAR **argv) { static const WCHAR create_groupW[] = {'C','r','e','a','t','e','G','r','o','u','p',0}; diff --git a/dlls/shell32/tests/progman_dde.c b/dlls/shell32/tests/progman_dde.c index b66c862..bfa9f65 100644 --- a/dlls/shell32/tests/progman_dde.c +++ b/dlls/shell32/tests/progman_dde.c @@ -171,6 +171,24 @@ static UINT dde_execute(DWORD instance, HCONV hconv, const char *command_str) return ret; } +static char *dde_request(DWORD instance, HCONV hconv, const char *request_str) +{ + static char data[2000]; + HDDEDATA hdata; + HSZ item; + DWORD result; + + item = DdeCreateStringHandleA(instance, request_str, CP_WINANSI); + ok(item != NULL, "DdeCreateStringHandle() failed: %u\n", DdeGetLastError(instance)); + + hdata = DdeClientTransaction(NULL, -1, hconv, item, CF_TEXT, XTYP_REQUEST, 2000, &result); + if (hdata == NULL) return NULL; + + DdeGetData(hdata, (BYTE *)data, 2000, 0); + + return data; +} + static BOOL check_window_exists(const char *name) { char title[MAX_PATH]; @@ -402,6 +420,40 @@ static void test_progman_dde2(DWORD instance, HCONV hConv) ok(!check_exists("Group2"), "directory should not exist\n"); } +static BOOL check_in_programs_list(const char *list, const char *group) +{ + while (1) + { + if (!strncmp(list, group, strlen(group)) && list[strlen(group)] == '\r') + return TRUE; + if (!(list = strchr(list, '\r'))) break; + list += 2; + } + return FALSE; +} + +static void test_request_groups(DWORD instance, HCONV hconv) +{ + char *list; + char programs[MAX_PATH]; + WIN32_FIND_DATAA finddata; + HANDLE hfind; + + list = dde_request(instance, hconv, "Groups"); + ok(list != NULL, "request failed: %u\n", DdeGetLastError(instance)); + strcpy(programs, ProgramsDir); + strcat(programs, "/*"); + hfind = FindFirstFileA(programs, &finddata); + do + { + if ((finddata.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) && finddata.cFileName[0] != '.') + { + ok(check_in_programs_list(list, finddata.cFileName), + "directory '%s' missing from group list\n", finddata.cFileName); + } + } while (FindNextFileA(hfind, &finddata)); +} + START_TEST(progman_dde) { DWORD instance = 0; @@ -430,6 +482,7 @@ START_TEST(progman_dde) test_parser(instance, hConv); test_progman_dde(instance, hConv); + test_request_groups(instance, hConv); /* Cleanup & Exit */ ok(DdeDisconnect(hConv), "DdeDisonnect() failed: %u\n", DdeGetLastError(instance));
1
0
0
0
Zebediah Figura : shell32: Implement the ExitProgman() command for Progman DDE.
by Alexandre Julliard
04 Dec '17
04 Dec '17
Module: wine Branch: master Commit: 7ddd41e3268419726b2097f964b07485685b1165 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=7ddd41e3268419726b2097f96…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Fri Dec 1 20:52:50 2017 -0600 shell32: Implement the ExitProgman() command for Progman DDE. Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/shell32/dde.c | 5 +++++ dlls/shell32/tests/progman_dde.c | 13 +++++++++++++ 2 files changed, 18 insertions(+) diff --git a/dlls/shell32/dde.c b/dlls/shell32/dde.c index 8ac6f9c..cfe5a05 100644 --- a/dlls/shell32/dde.c +++ b/dlls/shell32/dde.c @@ -128,6 +128,7 @@ static DWORD PROGMAN_OnExecute(WCHAR *command, int argc, WCHAR **argv) static const WCHAR add_itemW[] = {'A','d','d','I','t','e','m',0}; static const WCHAR delete_itemW[] = {'D','e','l','e','t','e','I','t','e','m',0}; static const WCHAR replace_itemW[] = {'R','e','p','l','a','c','e','I','t','e','m',0}; + static const WCHAR exit_progmanW[] = {'E','x','i','t','P','r','o','g','m','a','n',0}; static const WCHAR dotexeW[] = {'.','e','x','e',0}; static const WCHAR dotlnkW[] = {'.','l','n','k',0}; @@ -275,6 +276,10 @@ static DWORD PROGMAN_OnExecute(WCHAR *command, int argc, WCHAR **argv) if (!ret) return DDE_FNOTPROCESSED; } + else if (!strcmpiW(command, exit_progmanW)) + { + /* do nothing */ + } else { FIXME("unhandled command %s\n", debugstr_w(command)); diff --git a/dlls/shell32/tests/progman_dde.c b/dlls/shell32/tests/progman_dde.c index dd9b777..b66c862 100644 --- a/dlls/shell32/tests/progman_dde.c +++ b/dlls/shell32/tests/progman_dde.c @@ -270,6 +270,12 @@ static void test_parser(DWORD instance, HCONV hConv) error = dde_execute(instance, hConv, "[DeleteGroup(test)]"); ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); ok(!check_exists("test"), "directory should not exist\n"); + + error = dde_execute(instance, hConv, "[ExitProgman()]"); + ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); + + error = dde_execute(instance, hConv, "[ExitProgman]"); + ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); } /* 1st set of tests */ @@ -372,6 +378,13 @@ static void test_progman_dde(DWORD instance, HCONV hConv) error = dde_execute(instance, hConv, "[ShowGroup(Group2, 0)]"); ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); ok(check_window_exists("Group2"), "window not created\n"); + + error = dde_execute(instance, hConv, "[ExitProgman(1)]"); + ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); + + error = dde_execute(instance, hConv, "[AddItem(notepad,test4)]"); + ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); + ok(check_exists("Group2/test4.lnk"), "link not created\n"); } /* 2nd set of tests - 2nd connection */
1
0
0
0
Zebediah Figura : shell32: Implement the ReplaceItem() command for Progman DDE.
by Alexandre Julliard
04 Dec '17
04 Dec '17
Module: wine Branch: master Commit: 57a94970f532cf457787895268b5b59628885314 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=57a94970f532cf45778789526…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Fri Dec 1 20:52:49 2017 -0600 shell32: Implement the ReplaceItem() command for Progman DDE. Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/shell32/dde.c | 3 ++- dlls/shell32/tests/progman_dde.c | 12 ++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/dlls/shell32/dde.c b/dlls/shell32/dde.c index 7505c2c..8ac6f9c 100644 --- a/dlls/shell32/dde.c +++ b/dlls/shell32/dde.c @@ -127,6 +127,7 @@ static DWORD PROGMAN_OnExecute(WCHAR *command, int argc, WCHAR **argv) static const WCHAR show_groupW[] = {'S','h','o','w','G','r','o','u','p',0}; static const WCHAR add_itemW[] = {'A','d','d','I','t','e','m',0}; static const WCHAR delete_itemW[] = {'D','e','l','e','t','e','I','t','e','m',0}; + static const WCHAR replace_itemW[] = {'R','e','p','l','a','c','e','I','t','e','m',0}; static const WCHAR dotexeW[] = {'.','e','x','e',0}; static const WCHAR dotlnkW[] = {'.','l','n','k',0}; @@ -255,7 +256,7 @@ static DWORD PROGMAN_OnExecute(WCHAR *command, int argc, WCHAR **argv) if (FAILED(hres)) return DDE_FNOTPROCESSED; } - else if (!strcmpiW(command, delete_itemW)) + else if (!strcmpiW(command, delete_itemW) || !strcmpiW(command, replace_itemW)) { WCHAR *name; BOOL ret; diff --git a/dlls/shell32/tests/progman_dde.c b/dlls/shell32/tests/progman_dde.c index 478b3e6..dd9b777 100644 --- a/dlls/shell32/tests/progman_dde.c +++ b/dlls/shell32/tests/progman_dde.c @@ -325,6 +325,18 @@ static void test_progman_dde(DWORD instance, HCONV hConv) ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); ok(!check_exists("Group1/test1.lnk"), "link should not exist\n"); + error = dde_execute(instance, hConv, "[AddItem(notepad,test1)]"); + ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); + ok(check_exists("Group1/test1.lnk"), "link not created\n"); + + error = dde_execute(instance, hConv, "[ReplaceItem(test1)]"); + ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); + ok(!check_exists("Group1/test1.lnk"), "link should not exist\n"); + + error = dde_execute(instance, hConv, "[AddItem(regedit)]"); + ok(error == DMLERR_NO_ERROR, "expected DMLERR_NO_ERROR, got %u\n", error); + ok(check_exists("Group1/regedit.lnk"), "link not created\n"); + /* test ShowGroup() and test which group an item gets added to */ error = dde_execute(instance, hConv, "[ShowGroup(Group1)]"); ok(error == DMLERR_NOTPROCESSED, "expected DMLERR_NOTPROCESSED, got %u\n", error);
1
0
0
0
Francois Gouget : testbot/Janitor: Import File::Path. It' s needed for rmtree().
by Alexandre Julliard
04 Dec '17
04 Dec '17
Module: tools Branch: master Commit: 6fcc282a60ecdbef12b54c0d983178cdddb898eb URL:
http://source.winehq.org/git/tools.git/?a=commit;h=6fcc282a60ecdbef12b54c0d…
Author: Francois Gouget <fgouget(a)codeweavers.com> Date: Mon Dec 4 18:27:42 2017 +0100 testbot/Janitor: Import File::Path. It's needed for rmtree(). Signed-off-by: Francois Gouget <fgouget(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- testbot/bin/Janitor.pl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/testbot/bin/Janitor.pl b/testbot/bin/Janitor.pl index fd1b256..c07c21b 100755 --- a/testbot/bin/Janitor.pl +++ b/testbot/bin/Janitor.pl @@ -37,6 +37,8 @@ sub BEGIN } } +use File::Path; + use WineTestBot::Config; use WineTestBot::Jobs; use WineTestBot::Log;
1
0
0
0
Francois Gouget : testbot: Don' t try to use the Message-Id if the email had none.
by Alexandre Julliard
04 Dec '17
04 Dec '17
Module: tools Branch: master Commit: e9c3cacc6b62b1290e4b94c0a4e8a40c22264177 URL:
http://source.winehq.org/git/tools.git/?a=commit;h=e9c3cacc6b62b1290e4b94c0…
Author: Francois Gouget <fgouget(a)codeweavers.com> Date: Mon Dec 4 18:27:30 2017 +0100 testbot: Don't try to use the Message-Id if the email had none. This can happen if one directly feeds the output of git format-patch to the TestBot through formail, which can be useful for testing. Signed-off-by: Francois Gouget <fgouget(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- testbot/lib/WineTestBot/Patches.pm | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/testbot/lib/WineTestBot/Patches.pm b/testbot/lib/WineTestBot/Patches.pm index b5320dc..42118e6 100644 --- a/testbot/lib/WineTestBot/Patches.pm +++ b/testbot/lib/WineTestBot/Patches.pm @@ -101,9 +101,12 @@ sub FromSubmission($$) $self->Subject(substr($Subject, 0, $PropertyDescriptor->GetMaxLength())); my $MessageId = $Head->get("Message-Id"); - $MessageId =~ s/\s*\n\s*/ /gs; - $PropertyDescriptor = $self->GetPropertyDescriptorByName("MessageId"); - $self->MessageId(substr($MessageId, 0, $PropertyDescriptor->GetMaxLength())); + if ($MessageId) + { + $MessageId =~ s/\s*\n\s*/ /gs; + $PropertyDescriptor = $self->GetPropertyDescriptorByName("MessageId"); + $self->MessageId(substr($MessageId, 0, $PropertyDescriptor->GetMaxLength())); + } $self->Disposition("Processing"); }
1
0
0
0
Zebediah Figura : kernel32: Fix a couple internal uses of ANSI functions.
by Alexandre Julliard
01 Dec '17
01 Dec '17
Module: wine Branch: master Commit: 47e9e911acd2d0883ac1ccfc0a153db09ad78b41 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=47e9e911acd2d0883ac1ccfc0…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Fri Dec 1 12:18:55 2017 -0600 kernel32: Fix a couple internal uses of ANSI functions. Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/file.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/dlls/kernel32/file.c b/dlls/kernel32/file.c index 3e93b0d..4766830 100644 --- a/dlls/kernel32/file.c +++ b/dlls/kernel32/file.c @@ -74,6 +74,7 @@ static const UINT max_entry_size = offsetof( FILE_BOTH_DIRECTORY_INFORMATION, Fi static BOOL oem_file_apis; static const WCHAR wildcardsW[] = { '*','?',0 }; +static const WCHAR krnl386W[] = {'k','r','n','l','3','8','6','.','e','x','e','1','6',0}; /*********************************************************************** * create_file_OF @@ -1587,7 +1588,7 @@ HANDLE WINAPI CreateFileW( LPCWSTR filename, DWORD access, DWORD sharing, if (vxd_name && vxd_name[0]) { static HANDLE (*vxd_open)(LPCWSTR,DWORD,SECURITY_ATTRIBUTES*); - if (!vxd_open) vxd_open = (void *)GetProcAddress( GetModuleHandleA("krnl386.exe16"), + if (!vxd_open) vxd_open = (void *)GetProcAddress( GetModuleHandleW(krnl386W), "__wine_vxd_open" ); if (vxd_open && (ret = vxd_open( vxd_name, access, sa ))) goto done; } @@ -2613,7 +2614,7 @@ BOOL WINAPI DeviceIoControl(HANDLE hDevice, DWORD dwIoControlCode, static DeviceIoProc (*vxd_get_proc)(HANDLE); DeviceIoProc proc = NULL; - if (!vxd_get_proc) vxd_get_proc = (void *)GetProcAddress( GetModuleHandleA("krnl386.exe16"), + if (!vxd_get_proc) vxd_get_proc = (void *)GetProcAddress( GetModuleHandleW(krnl386W), "__wine_vxd_get_proc" ); if (vxd_get_proc) proc = vxd_get_proc( hDevice ); if (proc) return proc( dwIoControlCode, lpvInBuffer, cbInBuffer,
1
0
0
0
Alexandre Julliard : ntdll: Move suspending a thread on startup into attach_dlls().
by Alexandre Julliard
01 Dec '17
01 Dec '17
Module: wine Branch: master Commit: f64d2688d20952fb0085deeba98c952fd8bf1497 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=f64d2688d20952fb0085deeba…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 1 20:31:21 2017 +0100 ntdll: Move suspending a thread on startup into attach_dlls(). Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/loader.c | 8 +++++--- dlls/ntdll/ntdll_misc.h | 2 +- dlls/ntdll/signal_arm.c | 3 +-- dlls/ntdll/signal_arm64.c | 3 +-- dlls/ntdll/signal_i386.c | 3 +-- dlls/ntdll/signal_powerpc.c | 3 +-- dlls/ntdll/signal_x86_64.c | 3 +-- 7 files changed, 11 insertions(+), 14 deletions(-) diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c index c8c7f6a..170eefe 100644 --- a/dlls/ntdll/loader.c +++ b/dlls/ntdll/loader.c @@ -2990,12 +2990,14 @@ PIMAGE_NT_HEADERS WINAPI RtlImageNtHeader(HMODULE hModule) * Attach to all the loaded dlls. * If this is the first time, perform the full process initialization. */ -NTSTATUS attach_dlls( void *reserved ) +NTSTATUS attach_dlls( CONTEXT *context, BOOL suspend ) { NTSTATUS status; WINE_MODREF *wm; LPCWSTR load_path = NtCurrentTeb()->Peb->ProcessParameters->DllPath.Buffer; + if (suspend) wait_suspend( context ); + pthread_sigmask( SIG_UNBLOCK, &server_block_set, NULL ); if (process_detaching) return STATUS_SUCCESS; @@ -3029,7 +3031,7 @@ NTSTATUS attach_dlls( void *reserved ) debugstr_w(NtCurrentTeb()->Peb->ProcessParameters->ImagePathName.Buffer), status ); NtTerminateProcess( GetCurrentProcess(), status ); } - if ((status = process_attach( wm, reserved )) != STATUS_SUCCESS) + if ((status = process_attach( wm, context )) != STATUS_SUCCESS) { if (last_failed_modref) ERR( "%s failed to initialize, aborting\n", @@ -3038,7 +3040,7 @@ NTSTATUS attach_dlls( void *reserved ) debugstr_w(NtCurrentTeb()->Peb->ProcessParameters->ImagePathName.Buffer), status ); NtTerminateProcess( GetCurrentProcess(), status ); } - attach_implicitly_loaded_dlls( reserved ); + attach_implicitly_loaded_dlls( context ); virtual_release_address_space(); } else diff --git a/dlls/ntdll/ntdll_misc.h b/dlls/ntdll/ntdll_misc.h index 1393bbf..149462d 100644 --- a/dlls/ntdll/ntdll_misc.h +++ b/dlls/ntdll/ntdll_misc.h @@ -105,7 +105,7 @@ extern NTSTATUS validate_open_object_attributes( const OBJECT_ATTRIBUTES *attr ) /* module handling */ extern LIST_ENTRY tls_links DECLSPEC_HIDDEN; -extern NTSTATUS attach_dlls( void *unused ) DECLSPEC_HIDDEN; +extern NTSTATUS attach_dlls( CONTEXT *context, BOOL suspend ) DECLSPEC_HIDDEN; extern FARPROC RELAY_GetProcAddress( HMODULE module, const IMAGE_EXPORT_DIRECTORY *exports, DWORD exp_size, FARPROC proc, DWORD ordinal, const WCHAR *user ) DECLSPEC_HIDDEN; extern FARPROC SNOOP_GetProcAddress( HMODULE hmod, const IMAGE_EXPORT_DIRECTORY *exports, DWORD exp_size, diff --git a/dlls/ntdll/signal_arm.c b/dlls/ntdll/signal_arm.c index e1aa94f..59ae765 100644 --- a/dlls/ntdll/signal_arm.c +++ b/dlls/ntdll/signal_arm.c @@ -1230,8 +1230,7 @@ static void thread_startup( void *param ) context.Sp = (DWORD)NtCurrentTeb()->Tib.StackBase; context.Pc = (DWORD)call_thread_entry_point; - if (info->suspend) wait_suspend( &context ); - attach_dlls( &context ); + attach_dlls( &context, info->suspend ); set_cpu_context( &context ); } diff --git a/dlls/ntdll/signal_arm64.c b/dlls/ntdll/signal_arm64.c index 3dc92ad..36c7f2f 100644 --- a/dlls/ntdll/signal_arm64.c +++ b/dlls/ntdll/signal_arm64.c @@ -973,8 +973,7 @@ static void thread_startup( void *param ) context.Sp = (DWORD_PTR)NtCurrentTeb()->Tib.StackBase; context.Pc = (DWORD_PTR)call_thread_entry_point; - if (info->suspend) wait_suspend( &context ); - attach_dlls( &context ); + attach_dlls( &context, info->suspend ); call_thread_entry_point( (LPTHREAD_START_ROUTINE)context.X0, (void *)context.X1 ); } diff --git a/dlls/ntdll/signal_i386.c b/dlls/ntdll/signal_i386.c index f894816..1c04c82 100644 --- a/dlls/ntdll/signal_i386.c +++ b/dlls/ntdll/signal_i386.c @@ -2984,8 +2984,7 @@ void DECLSPEC_HIDDEN call_process_func( LPTHREAD_START_ROUTINE entry, void *arg */ void DECLSPEC_HIDDEN thread_startup( CONTEXT *context, BOOL suspend ) { - if (suspend) wait_suspend( context ); - attach_dlls( context ); + attach_dlls( context, suspend ); virtual_clear_thread_stack(); set_cpu_context( context ); } diff --git a/dlls/ntdll/signal_powerpc.c b/dlls/ntdll/signal_powerpc.c index b012497..5122c54 100644 --- a/dlls/ntdll/signal_powerpc.c +++ b/dlls/ntdll/signal_powerpc.c @@ -1175,8 +1175,7 @@ static void thread_startup( void *param ) context.Gpr4 = (DWORD)info->arg; context.Iar = (DWORD)call_thread_entry_point; - if (info->suspend) wait_suspend( &context ); - attach_dlls( &context ); + attach_dlls( &context, info->suspend ); call_thread_entry_point( (LPTHREAD_START_ROUTINE)context.Gpr3, (void *)context.Gpr4 ); } diff --git a/dlls/ntdll/signal_x86_64.c b/dlls/ntdll/signal_x86_64.c index 3994569..af2682e 100644 --- a/dlls/ntdll/signal_x86_64.c +++ b/dlls/ntdll/signal_x86_64.c @@ -4145,8 +4145,7 @@ __ASM_GLOBAL_FUNC( call_thread_exit_func, */ void DECLSPEC_HIDDEN thread_startup( CONTEXT *context, BOOL suspend ) { - if (suspend) wait_suspend( context ); - attach_dlls( context ); + attach_dlls( context, suspend ); virtual_clear_thread_stack(); set_cpu_context( context ); }
1
0
0
0
Alexandre Julliard : ntdll: Run the entire thread initialization code on the thread stack on remaining platforms.
by Alexandre Julliard
01 Dec '17
01 Dec '17
Module: wine Branch: master Commit: c3dd077d34232611c8b2ee38789114da45e71ef4 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=c3dd077d34232611c8b2ee387…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 1 19:24:21 2017 +0100 ntdll: Run the entire thread initialization code on the thread stack on remaining platforms. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/ntdll_misc.h | 1 - dlls/ntdll/signal_arm.c | 117 ++++++++++++++++++++-------------------- dlls/ntdll/signal_arm64.c | 126 +++++++++++++++++++++----------------------- dlls/ntdll/signal_powerpc.c | 126 +++++++++++++++++++++----------------------- 4 files changed, 177 insertions(+), 193 deletions(-) Diff:
http://source.winehq.org/git/wine.git/?a=commitdiff;h=c3dd077d34232611c8b2e…
1
0
0
0
Alexandre Julliard : ntdll: Run the entire thread initialization code on the thread stack on x86-64.
by Alexandre Julliard
01 Dec '17
01 Dec '17
Module: wine Branch: master Commit: 32c2cfb861098f21accccc2ebab6a05947c4c603 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=32c2cfb861098f21accccc2eb…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Fri Dec 1 19:20:22 2017 +0100 ntdll: Run the entire thread initialization code on the thread stack on x86-64. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ntdll/signal_x86_64.c | 167 ++++++++++++++++++++++++--------------------- 1 file changed, 88 insertions(+), 79 deletions(-) diff --git a/dlls/ntdll/signal_x86_64.c b/dlls/ntdll/signal_x86_64.c index 22f6ed8..3994569 100644 --- a/dlls/ntdll/signal_x86_64.c +++ b/dlls/ntdll/signal_x86_64.c @@ -3053,15 +3053,6 @@ static void *mac_thread_gsbase(void) #endif -/*********************************************************************** - * start_process - */ -static void CDECL start_process( LPTHREAD_START_ROUTINE entry, PEB *peb ) -{ - call_thread_entry_point( kernel32_start_process, entry ); -} - - /********************************************************************** * signal_init_thread */ @@ -3144,70 +3135,6 @@ void signal_init_process(void) } -struct startup_info -{ - LPTHREAD_START_ROUTINE entry; - void *arg; -}; - -static void thread_startup( void *param ) -{ - struct startup_info *info = param; - call_thread_entry_point( info->entry, info->arg ); -} - - -/*********************************************************************** - * signal_start_thread - */ -void signal_start_thread( LPTHREAD_START_ROUTINE entry, void *arg, BOOL suspend ) -{ - CONTEXT context = { 0 }; - struct startup_info info = { entry, arg }; - - /* build the initial context */ - context.ContextFlags = CONTEXT_FULL; - __asm__( "movw %%cs,%0" : "=m" (context.SegCs) ); - __asm__( "movw %%ss,%0" : "=m" (context.SegSs) ); - __asm__( "fxsave %0" : "=m" (context.u.FltSave) ); - context.Rcx = (ULONG_PTR)entry; - context.Rdx = (ULONG_PTR)arg; - context.Rsp = (ULONG_PTR)NtCurrentTeb()->Tib.StackBase - 0x28; - context.Rip = (ULONG_PTR)call_thread_entry_point; - - if (suspend) wait_suspend( &context ); - - wine_call_on_stack( attach_dlls, (void *)1, NtCurrentTeb()->Tib.StackBase ); - TRACE_(relay)( "\1Starting thread proc %p (arg=%p)\n", entry, arg ); - wine_switch_to_stack( thread_startup, &info, NtCurrentTeb()->Tib.StackBase ); -} - - -/********************************************************************** - * signal_start_process - */ -void signal_start_process( LPTHREAD_START_ROUTINE entry, BOOL suspend ) -{ - CONTEXT context = { 0 }; - - /* build the initial context */ - context.ContextFlags = CONTEXT_FULL; - __asm__( "movw %%cs,%0" : "=m" (context.SegCs) ); - __asm__( "movw %%ss,%0" : "=m" (context.SegSs) ); - __asm__( "fxsave %0" : "=m" (context.u.FltSave) ); - context.Rcx = (ULONG_PTR)entry; - context.Rdx = (ULONG_PTR)NtCurrentTeb()->Peb; - context.Rsp = (ULONG_PTR)NtCurrentTeb()->Tib.StackBase - 0x28; - context.Rip = (ULONG_PTR)start_process; - - if (suspend) wait_suspend( &context ); - - wine_call_on_stack( attach_dlls, (void *)1, (char *)NtCurrentTeb()->Tib.StackBase - page_size ); - virtual_clear_thread_stack(); - set_cpu_context( &context ); -} - - /********************************************************************** * RtlAddFunctionTable (NTDLL.@) */ @@ -4130,11 +4057,11 @@ USHORT WINAPI RtlCaptureStackBackTrace( ULONG skip, ULONG count, PVOID *buffer, /*********************************************************************** * call_thread_func */ -void DECLSPEC_HIDDEN call_thread_func( LPTHREAD_START_ROUTINE entry, void *arg, void *frame ) +static void WINAPI call_thread_func( LPTHREAD_START_ROUTINE entry, void *arg ) { - amd64_thread_data()->exit_frame = frame; __TRY { + TRACE_(relay)( "\1Starting thread proc %p (arg=%p)\n", entry, arg ); RtlExitUserThread( entry( arg )); } __EXCEPT(unhandled_exception_filter) @@ -4145,8 +4072,28 @@ void DECLSPEC_HIDDEN call_thread_func( LPTHREAD_START_ROUTINE entry, void *arg, abort(); /* should not be reached */ } -extern void DECLSPEC_NORETURN call_thread_entry_point( LPTHREAD_START_ROUTINE entry, void *arg ); -__ASM_GLOBAL_FUNC( call_thread_entry_point, + +/*********************************************************************** + * call_process_func + */ +static void WINAPI call_process_func( LPTHREAD_START_ROUTINE entry, void *arg ) +{ + __TRY + { + RtlExitUserThread( kernel32_start_process( entry )); + } + __EXCEPT(unhandled_exception_filter) + { + NtTerminateThread( GetCurrentThread(), GetExceptionCode() ); + } + __ENDTRY + abort(); /* should not be reached */ +} + + +extern void DECLSPEC_NORETURN start_thread( LPTHREAD_START_ROUTINE entry, void *arg, BOOL suspend, + void *relay, void *stack, void **exit_frame ); +__ASM_GLOBAL_FUNC( start_thread, "subq $56,%rsp\n\t" __ASM_CFI(".cfi_adjust_cfa_offset 56\n\t") "movq %rbp,48(%rsp)\n\t" @@ -4161,8 +4108,24 @@ __ASM_GLOBAL_FUNC( call_thread_entry_point, __ASM_CFI(".cfi_rel_offset %r14,16\n\t") "movq %r15,8(%rsp)\n\t" __ASM_CFI(".cfi_rel_offset %r15,8\n\t") - "movq %rsp,%rdx\n\t" - "call " __ASM_NAME("call_thread_func") ); + /* store exit frame */ + "movq %rsp,(%r9)\n\t" + /* build initial context on thread stack */ + "leaq -0x500(%r8),%r10\n\t" /* sizeof(context) + 0x30 for function params */ + "movq $0x001000b,0x30(%r10)\n\t" /* context->ContextFlags = CONTEXT_FULL */ + "movw %cs,0x38(%r10)\n\t" /* context->SegCs */ + "movw %ss,0x42(%r10)\n\t" /* context->SegSs */ + "movq %rdi,0x80(%r10)\n\t" /* context->Rcx = entry */ + "movq %rsi,0x88(%r10)\n\t" /* context->Rdx = arg */ + "leaq -0x28(%r8),%rax\n\t" + "movq %rax,0x98(%r10)\n\t" /* context->Rsp */ + "movq %rcx,0xf8(%r10)\n\t" /* context->Rip = relay */ + "fxsave 0x100(%r10)\n\t" /* context->FtlSave */ + /* switch to thread stack and call thread_startup() */ + "movq %r10,%rsp\n\t" + "movq %r10,%rdi\n\t" /* context */ + "movq %rdx,%rsi\n\t" /* suspend */ + "call " __ASM_NAME("thread_startup") ) extern void DECLSPEC_NORETURN call_thread_exit_func( int status, void (*func)(int), void *frame ); __ASM_GLOBAL_FUNC( call_thread_exit_func, @@ -4176,6 +4139,52 @@ __ASM_GLOBAL_FUNC( call_thread_exit_func, __ASM_CFI(".cfi_rel_offset %r15,8\n\t") "call *%rsi" ); + +/*********************************************************************** + * thread_startup + */ +void DECLSPEC_HIDDEN thread_startup( CONTEXT *context, BOOL suspend ) +{ + if (suspend) wait_suspend( context ); + attach_dlls( context ); + virtual_clear_thread_stack(); + set_cpu_context( context ); +} + + +/*********************************************************************** + * signal_start_thread + * + * Thread startup sequence: + * signal_start_thread() + * -> start_thread() + * -> thread_startup() + * -> call_thread_func() + */ +void signal_start_thread( LPTHREAD_START_ROUTINE entry, void *arg, BOOL suspend ) +{ + start_thread( entry, arg, suspend, call_thread_func, + NtCurrentTeb()->Tib.StackBase, &amd64_thread_data()->exit_frame ); +} + + +/********************************************************************** + * signal_start_process + * + * Process startup sequence: + * signal_start_process() + * -> start_thread() + * -> thread_startup() + * -> call_process_func() + * -> kernel32_start_process() + */ +void signal_start_process( LPTHREAD_START_ROUTINE entry, BOOL suspend ) +{ + start_thread( entry, NtCurrentTeb()->Peb, suspend, call_process_func, + NtCurrentTeb()->Tib.StackBase, &amd64_thread_data()->exit_frame ); +} + + /*********************************************************************** * RtlExitUserThread (NTDLL.@) */
1
0
0
0
← Newer
1
...
36
37
38
39
40
41
42
...
45
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
Results per page:
10
25
50
100
200