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
August 2023
----- 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
1 participants
667 discussions
Start a n
N
ew thread
Piotr Caban : msvcr120/tests: Remove workaround for not implemented _StructuredTaskCollection::ctor().
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: wine Branch: master Commit: 5672c08086dec1f1c7fc8d598fedb49124670c03 URL:
https://gitlab.winehq.org/wine/wine/-/commit/5672c08086dec1f1c7fc8d598fedb4…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Fri Aug 25 15:07:29 2023 +0200 msvcr120/tests: Remove workaround for not implemented _StructuredTaskCollection::ctor(). --- dlls/msvcr120/tests/msvcr120.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/dlls/msvcr120/tests/msvcr120.c b/dlls/msvcr120/tests/msvcr120.c index 838338c83f8..11a8594e749 100644 --- a/dlls/msvcr120/tests/msvcr120.c +++ b/dlls/msvcr120/tests/msvcr120.c @@ -1436,11 +1436,7 @@ static void test_StructuredTaskCollection(void) context = p_Context_CurrentContext(); memset(&task_coll, 0x55, sizeof(task_coll)); - if (!call_func2(p__StructuredTaskCollection_ctor, &task_coll, NULL)) - { - skip("_StructuredTaskCollection constructor not implemented\n"); - return; - } + call_func2(p__StructuredTaskCollection_ctor, &task_coll, NULL); todo_wine ok(task_coll.unk2 == 0x1fffffff, "_StructuredTaskCollection ctor set wrong unk2: 0x%x != 0x1fffffff\n", task_coll.unk2); ok(task_coll.unk3 == NULL,
1
0
0
0
Piotr Caban : msvcr110: Add _Cancellation_beacon class implementation.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: wine Branch: master Commit: 969ed7edea48f10c5d9f8bd49400292c5d1742ce URL:
https://gitlab.winehq.org/wine/wine/-/commit/969ed7edea48f10c5d9f8bd4940029…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Fri Aug 25 16:22:43 2023 +0200 msvcr110: Add _Cancellation_beacon class implementation. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=54756
--- dlls/concrt140/concrt140.spec | 12 +++--- dlls/msvcr110/msvcr110.spec | 12 +++--- dlls/msvcr120/msvcr120.spec | 12 +++--- dlls/msvcr120_app/msvcr120_app.spec | 12 +++--- dlls/msvcrt/concurrency.c | 80 +++++++++++++++++++++++++++++++++++++ 5 files changed, 104 insertions(+), 24 deletions(-)
1
0
0
0
Piotr Caban : msvcr110: Add Context::IsCurrentTaskCollectionCanceling implementation.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: wine Branch: master Commit: 3f55fb72caea5e32d81abfec9a4ea7d64a91a5b8 URL:
https://gitlab.winehq.org/wine/wine/-/commit/3f55fb72caea5e32d81abfec9a4ea7…
Author: Piotr Caban <piotr(a)codeweavers.com> Date: Fri Aug 25 19:47:25 2023 +0200 msvcr110: Add Context::IsCurrentTaskCollectionCanceling implementation. --- dlls/msvcrt/concurrency.c | 50 +++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 42 insertions(+), 8 deletions(-) diff --git a/dlls/msvcrt/concurrency.c b/dlls/msvcrt/concurrency.c index eb9e8f9ee32..395188c257d 100644 --- a/dlls/msvcrt/concurrency.c +++ b/dlls/msvcrt/concurrency.c @@ -103,6 +103,7 @@ typedef struct { unsigned int id; union allocator_cache_entry *allocator_cache[8]; LONG blocked; + struct _StructuredTaskCollection *task_collection; } ExternalContextBase; extern const vtable_ptr ExternalContextBase_vtable; static void ExternalContextBase_ctor(ExternalContextBase*); @@ -175,7 +176,7 @@ typedef struct } SpinWait; #define FINISHED_INITIAL 0x80000000 -typedef struct +typedef struct _StructuredTaskCollection { void *unk1; unsigned int unk2; @@ -187,6 +188,8 @@ typedef struct void *event; } _StructuredTaskCollection; +bool __thiscall _StructuredTaskCollection__IsCanceling(_StructuredTaskCollection*); + typedef enum { TASK_COLLECTION_SUCCESS = 1, @@ -851,7 +854,17 @@ void __cdecl Context__SpinYield(void) /* ?IsCurrentTaskCollectionCanceling@Context@Concurrency@@SA_NXZ */ bool __cdecl Context_IsCurrentTaskCollectionCanceling(void) { - FIXME("()\n"); + ExternalContextBase *ctx = (ExternalContextBase*)try_get_current_context(); + + TRACE("()\n"); + + if (ctx && ctx->context.vtable != &ExternalContextBase_vtable) { + ERR("unknown context set\n"); + return FALSE; + } + + if (ctx && ctx->task_collection) + return _StructuredTaskCollection__IsCanceling(ctx->task_collection); return FALSE; } @@ -2166,23 +2179,44 @@ static LONG CALLBACK execute_chore_except(EXCEPTION_POINTERS *pexc, void *_data) return EXCEPTION_EXECUTE_HANDLER; } +static void CALLBACK execute_chore_finally(BOOL normal, void *data) +{ + ExternalContextBase *ctx = (ExternalContextBase*)try_get_current_context(); + _StructuredTaskCollection *old_collection = data; + + if (ctx && ctx->context.vtable == &ExternalContextBase_vtable) + ctx->task_collection = old_collection; +} + static void execute_chore(_UnrealizedChore *chore, _StructuredTaskCollection *task_collection) { + ExternalContextBase *ctx = (ExternalContextBase*)try_get_current_context(); struct execute_chore_data data = { chore, task_collection }; + _StructuredTaskCollection *old_collection; TRACE("(%p %p)\n", chore, task_collection); - __TRY + if (ctx && ctx->context.vtable == &ExternalContextBase_vtable) { - if (!((ULONG_PTR)task_collection->exception & ~STRUCTURED_TASK_COLLECTION_STATUS_MASK) && - chore->chore_proc) - chore->chore_proc(chore); + old_collection = ctx->task_collection; + ctx->task_collection = task_collection; } - __EXCEPT_CTX(execute_chore_except, &data) + + __TRY { + __TRY + { + if (!((ULONG_PTR)task_collection->exception & ~STRUCTURED_TASK_COLLECTION_STATUS_MASK) && + chore->chore_proc) + chore->chore_proc(chore); + } + __EXCEPT_CTX(execute_chore_except, &data) + { + } + __ENDTRY } - __ENDTRY + __FINALLY_CTX(execute_chore_finally, old_collection) } static void CALLBACK chore_wrapper_finally(BOOL normal, void *data)
1
0
0
0
Alex Henrie : dmusic: Use CRT allocation functions.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: wine Branch: master Commit: 4ef31ae987b80ae7794c0a72a99e9999efda8a50 URL:
https://gitlab.winehq.org/wine/wine/-/commit/4ef31ae987b80ae7794c0a72a99e99…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Tue Aug 22 22:28:38 2023 -0600 dmusic: Use CRT allocation functions. --- dlls/dmusic/buffer.c | 10 +++++----- dlls/dmusic/clock.c | 4 ++-- dlls/dmusic/collection.c | 14 +++++++------- dlls/dmusic/dmobject.c | 7 +++---- dlls/dmusic/dmusic.c | 29 +++++++++++------------------ dlls/dmusic/download.c | 4 ++-- dlls/dmusic/instrument.c | 23 ++++++++++------------- dlls/dmusic/port.c | 29 ++++++++++++++--------------- 8 files changed, 54 insertions(+), 66 deletions(-)
1
0
0
0
Biswapriyo Nath : uiautomationcore: Fix typo with TreeScope_Subtree name.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: wine Branch: master Commit: 096377be4219e2bebe3ed8535a0ae7965536a489 URL:
https://gitlab.winehq.org/wine/wine/-/commit/096377be4219e2bebe3ed8535a0ae7…
Author: Biswapriyo Nath <nathbappai(a)gmail.com> Date: Sun Aug 27 18:41:52 2023 +0530 uiautomationcore: Fix typo with TreeScope_Subtree name. --- dlls/uiautomationcore/tests/uiautomation.c | 20 ++++++++++---------- dlls/uiautomationcore/uia_com_client.c | 6 +++--- include/uiautomationclient.idl | 2 +- include/uiautomationcoreapi.h | 2 +- 4 files changed, 15 insertions(+), 15 deletions(-) diff --git a/dlls/uiautomationcore/tests/uiautomation.c b/dlls/uiautomationcore/tests/uiautomation.c index af640dbe00f..a733e183312 100644 --- a/dlls/uiautomationcore/tests/uiautomation.c +++ b/dlls/uiautomationcore/tests/uiautomation.c @@ -11544,7 +11544,7 @@ static void test_CUIAutomation_cache_request_iface(IUIAutomation *uia_iface) hr = IUIAutomationCacheRequest_put_TreeScope(cache_req, TreeScope_Ancestors | TreeScope_Element); ok(hr == E_INVALIDARG, "Unexpected hr %#lx.\n", hr); - hr = IUIAutomationCacheRequest_put_TreeScope(cache_req, ~(TreeScope_SubTree | TreeScope_Parent | TreeScope_Ancestors)); + hr = IUIAutomationCacheRequest_put_TreeScope(cache_req, ~(TreeScope_Subtree | TreeScope_Parent | TreeScope_Ancestors)); ok(hr == E_INVALIDARG, "Unexpected hr %#lx.\n", hr); /* Invalid values don't change anything. */ @@ -12133,7 +12133,7 @@ static void test_Element_Find(IUIAutomation *uia_iface) * Equivalent to: Maximum find depth of -1, find first is FALSE, exclude * root is FALSE. */ - hr = IUIAutomationElement_FindAllBuildCache(element, TreeScope_SubTree, condition, cache_req, &element_arr); + hr = IUIAutomationElement_FindAllBuildCache(element, TreeScope_Subtree, condition, cache_req, &element_arr); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); set_elem_desc(&exp_elems[0], &Provider, NULL, GetCurrentProcessId(), 2, 2); @@ -12378,7 +12378,7 @@ static void test_Element_Find(IUIAutomation *uia_iface) * root is FALSE. Provider_child_child2 is the only element in the tree * to match our condition. */ - hr = IUIAutomationElement_FindFirstBuildCache(element, TreeScope_SubTree, condition, cache_req, &element2); + hr = IUIAutomationElement_FindFirstBuildCache(element, TreeScope_Subtree, condition, cache_req, &element2); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); ok(Provider_child_child2.ref == 2, "Unexpected refcnt %ld\n", Provider_child_child2.ref); @@ -12443,7 +12443,7 @@ static void test_Element_Find(IUIAutomation *uia_iface) set_provider_prop_override(&Provider_child, &prop_override, 1); set_provider_prop_override(&Provider_child_child, &prop_override, 1); - hr = IUIAutomationElement_FindFirst(element, TreeScope_SubTree, condition, &element2); + hr = IUIAutomationElement_FindFirst(element, TreeScope_Subtree, condition, &element2); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); ok(Provider_child_child2.ref == 2, "Unexpected refcnt %ld\n", Provider_child_child2.ref); @@ -13231,11 +13231,11 @@ static void test_IUIAutomationEventHandler(IUIAutomation *uia_iface, IUIAutomati /* * Invalid input argument tests. */ - hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_LiveRegionChangedEventId, NULL, TreeScope_SubTree, NULL, + hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_LiveRegionChangedEventId, NULL, TreeScope_Subtree, NULL, &AutomationEventHandler.IUIAutomationEventHandler_iface); ok(hr == E_POINTER, "Unexpected hr %#lx.\n", hr); - hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_LiveRegionChangedEventId, elem, TreeScope_SubTree, NULL, + hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_LiveRegionChangedEventId, elem, TreeScope_Subtree, NULL, NULL); ok(hr == E_POINTER, "Unexpected hr %#lx.\n", hr); @@ -13260,14 +13260,14 @@ static void test_IUIAutomationEventHandler(IUIAutomation *uia_iface, IUIAutomati * AddFocusChangedEventHandler. Trying to register it on a regular event * handler returns E_INVALIDARG. */ - hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_AutomationFocusChangedEventId, elem, TreeScope_SubTree, NULL, + hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_AutomationFocusChangedEventId, elem, TreeScope_Subtree, NULL, &AutomationEventHandler.IUIAutomationEventHandler_iface); ok(hr == E_INVALIDARG, "Unexpected hr %#lx.\n", hr); /* Windows 11 queries the HWND for the element when adding a new handler. */ set_uia_hwnd_expects(3, 2, 2, 3, 0); /* All other event IDs are fine, only focus events are blocked. */ - hr = IUIAutomation_AddAutomationEventHandler(uia_iface, 1, elem, TreeScope_SubTree, NULL, + hr = IUIAutomation_AddAutomationEventHandler(uia_iface, 1, elem, TreeScope_Subtree, NULL, &AutomationEventHandler.IUIAutomationEventHandler_iface); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); ok(AutomationEventHandler.ref > 1, "Unexpected refcnt %ld\n", AutomationEventHandler.ref); @@ -13282,7 +13282,7 @@ static void test_IUIAutomationEventHandler(IUIAutomation *uia_iface, IUIAutomati * Test event raising behavior. */ set_uia_hwnd_expects(3, 2, 2, 3, 0); - hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_LiveRegionChangedEventId, elem, TreeScope_SubTree, NULL, + hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_LiveRegionChangedEventId, elem, TreeScope_Subtree, NULL, &AutomationEventHandler.IUIAutomationEventHandler_iface); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); ok(AutomationEventHandler.ref > 1, "Unexpected refcnt %ld\n", AutomationEventHandler.ref); @@ -13349,7 +13349,7 @@ static void test_IUIAutomationEventHandler(IUIAutomation *uia_iface, IUIAutomati * runtime-id, the only way to unregister the event handler is to call * RemoveAllEventHandlers(). */ - hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_LiveRegionChangedEventId, elem2, TreeScope_SubTree, NULL, + hr = IUIAutomation_AddAutomationEventHandler(uia_iface, UIA_LiveRegionChangedEventId, elem2, TreeScope_Subtree, NULL, &AutomationEventHandler.IUIAutomationEventHandler_iface); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); ok(AutomationEventHandler.ref > 1, "Unexpected refcnt %ld\n", AutomationEventHandler.ref); diff --git a/dlls/uiautomationcore/uia_com_client.c b/dlls/uiautomationcore/uia_com_client.c index 9242a279faa..c2b723660b1 100644 --- a/dlls/uiautomationcore/uia_com_client.c +++ b/dlls/uiautomationcore/uia_com_client.c @@ -743,7 +743,7 @@ static HRESULT WINAPI uia_cache_request_put_TreeScope(IUIAutomationCacheRequest TRACE("%p, %#x\n", iface, scope); - if (!scope || (scope & ~TreeScope_SubTree)) + if (!scope || (scope & ~TreeScope_Subtree)) return E_INVALIDARG; if ((scope & TreeScope_Children) || (scope & TreeScope_Descendants)) @@ -1366,7 +1366,7 @@ static HRESULT set_find_params_struct(struct UiaFindParams *params, IUIAutomatio if (FAILED(hr)) return hr; - if (!scope || (scope & (~TreeScope_SubTree))) + if (!scope || (scope & (~TreeScope_Subtree))) return E_INVALIDARG; params->FindFirst = find_first; @@ -3447,7 +3447,7 @@ static HRESULT WINAPI uia_iface_AddFocusChangedEventHandler(IUIAutomation6 *ifac return hr; } - hr = uia_add_com_event_handler(iface, UIA_AutomationFocusChangedEventId, elem, TreeScope_SubTree, cache_req, + hr = uia_add_com_event_handler(iface, UIA_AutomationFocusChangedEventId, elem, TreeScope_Subtree, cache_req, &IID_IUIAutomationFocusChangedEventHandler, handler_unk); IUIAutomationElement_Release(elem); IUnknown_Release(handler_unk); diff --git a/include/uiautomationclient.idl b/include/uiautomationclient.idl index 7a0b50288d4..1026230f1c2 100644 --- a/include/uiautomationclient.idl +++ b/include/uiautomationclient.idl @@ -27,7 +27,7 @@ enum TreeScope { TreeScope_Descendants = 0x04, TreeScope_Parent = 0x08, TreeScope_Ancestors = 0x10, - TreeScope_SubTree = TreeScope_Element | TreeScope_Children | TreeScope_Descendants, + TreeScope_Subtree = TreeScope_Element | TreeScope_Children | TreeScope_Descendants, }; enum PropertyConditionFlags { diff --git a/include/uiautomationcoreapi.h b/include/uiautomationcoreapi.h index 0c2ad7b742d..a9a3c75c13c 100644 --- a/include/uiautomationcoreapi.h +++ b/include/uiautomationcoreapi.h @@ -371,7 +371,7 @@ enum TreeScope { TreeScope_Descendants = 0x04, TreeScope_Parent = 0x08, TreeScope_Ancestors = 0x10, - TreeScope_SubTree = TreeScope_Element | TreeScope_Children | TreeScope_Descendants, + TreeScope_Subtree = TreeScope_Element | TreeScope_Children | TreeScope_Descendants, }; enum PropertyConditionFlags {
1
0
0
0
Marcus Meissner : cryptui: LoadStringW gets characters as size, not bytes.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: wine Branch: master Commit: 7d72397a0821120605944721c1e47895e6cf10db URL:
https://gitlab.winehq.org/wine/wine/-/commit/7d72397a0821120605944721c1e478…
Author: Marcus Meissner <marcus(a)jet.franken.de> Date: Sun Aug 27 13:47:21 2023 +0200 cryptui: LoadStringW gets characters as size, not bytes. --- dlls/cryptui/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/cryptui/main.c b/dlls/cryptui/main.c index 357eec02460..ee5d7037366 100644 --- a/dlls/cryptui/main.c +++ b/dlls/cryptui/main.c @@ -923,7 +923,7 @@ static void get_cert_usages(PCCERT_CONTEXT cert, LPWSTR *str) size = MAX_STRING_LEN * sizeof(WCHAR); *str = malloc(size); if (*str) - LoadStringW(hInstance, IDS_ALLOWED_PURPOSE_NONE, *str, size); + LoadStringW(hInstance, IDS_ALLOWED_PURPOSE_NONE, *str, MAX_STRING_LEN); } } else @@ -931,7 +931,7 @@ static void get_cert_usages(PCCERT_CONTEXT cert, LPWSTR *str) size = MAX_STRING_LEN * sizeof(WCHAR); *str = malloc(size); if (*str) - LoadStringW(hInstance, IDS_ALLOWED_PURPOSE_ALL, *str, size); + LoadStringW(hInstance, IDS_ALLOWED_PURPOSE_ALL, *str, MAX_STRING_LEN); } }
1
0
0
0
Alex Henrie : mpr: Fix double free in WNetGetResourceInformationA.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: wine Branch: master Commit: afdd2191944337414f0e311adfaadfab615369ca URL:
https://gitlab.winehq.org/wine/wine/-/commit/afdd2191944337414f0e311adfaadf…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Sat Aug 26 20:07:34 2023 -0600 mpr: Fix double free in WNetGetResourceInformationA. --- dlls/mpr/wnet.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/dlls/mpr/wnet.c b/dlls/mpr/wnet.c index 999a2a0e80c..e9c5321cee1 100644 --- a/dlls/mpr/wnet.c +++ b/dlls/mpr/wnet.c @@ -1684,7 +1684,7 @@ DWORD WINAPI WNetGetResourceInformationA( LPNETRESOURCEA lpNetResource, if (ret == WN_SUCCESS) { LPWSTR lpSystemW = NULL; - LPVOID lpBufferW; + NETRESOURCEW *lpBufferW; size = 1024; lpBufferW = HeapAlloc(GetProcessHeap(), 0, size); if (lpBufferW) @@ -1705,12 +1705,10 @@ DWORD WINAPI WNetGetResourceInformationA( LPNETRESOURCEA lpNetResource, { ret = _thunkNetResourceArrayWToA(lpBufferW, &count, lpBuffer, cbBuffer); - HeapFree(GetProcessHeap(), 0, lpNetResourceW); - lpNetResourceW = lpBufferW; size = sizeof(NETRESOURCEA); - size += WideCharToMultiByte(CP_ACP, 0, lpNetResourceW->lpRemoteName, + size += WideCharToMultiByte(CP_ACP, 0, lpBufferW->lpRemoteName, -1, NULL, 0, NULL, NULL); - size += WideCharToMultiByte(CP_ACP, 0, lpNetResourceW->lpProvider, + size += WideCharToMultiByte(CP_ACP, 0, lpBufferW->lpProvider, -1, NULL, 0, NULL, NULL); len = WideCharToMultiByte(CP_ACP, 0, lpSystemW,
1
0
0
0
Conor McCarthy : vkd3d-shader/tpf: Handle the swizzle type bitfield in dst param tokens.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: vkd3d Branch: master Commit: 61841e9423f91d9ef8df3c070f58625609dac9d2 URL:
https://gitlab.winehq.org/wine/vkd3d/-/commit/61841e9423f91d9ef8df3c070f586…
Author: Conor McCarthy <cmccarthy(a)codeweavers.com> Date: Tue Aug 8 12:29:20 2023 +1000 vkd3d-shader/tpf: Handle the swizzle type bitfield in dst param tokens. --- libs/vkd3d-shader/tpf.c | 28 ++++++++++++++++++++++++++-- libs/vkd3d-shader/vkd3d_shader_private.h | 1 + 2 files changed, 27 insertions(+), 2 deletions(-) diff --git a/libs/vkd3d-shader/tpf.c b/libs/vkd3d-shader/tpf.c index 2fcda112..7949be15 100644 --- a/libs/vkd3d-shader/tpf.c +++ b/libs/vkd3d-shader/tpf.c @@ -2111,8 +2111,9 @@ static bool shader_sm4_read_src_param(struct vkd3d_shader_sm4_parser *priv, cons static bool shader_sm4_read_dst_param(struct vkd3d_shader_sm4_parser *priv, const uint32_t **ptr, const uint32_t *end, enum vkd3d_data_type data_type, struct vkd3d_shader_dst_param *dst_param) { + enum vkd3d_sm4_swizzle_type swizzle_type; enum vkd3d_shader_src_modifier modifier; - unsigned int dimension; + unsigned int dimension, swizzle; DWORD token; if (*ptr >= end) @@ -2145,7 +2146,30 @@ static bool shader_sm4_read_dst_param(struct vkd3d_shader_sm4_parser *priv, cons break; case VKD3D_SM4_DIMENSION_VEC4: - dst_param->write_mask = (token & VKD3D_SM4_WRITEMASK_MASK) >> VKD3D_SM4_WRITEMASK_SHIFT; + swizzle_type = (token & VKD3D_SM4_SWIZZLE_TYPE_MASK) >> VKD3D_SM4_SWIZZLE_TYPE_SHIFT; + switch (swizzle_type) + { + case VKD3D_SM4_SWIZZLE_NONE: + dst_param->write_mask = (token & VKD3D_SM4_WRITEMASK_MASK) >> VKD3D_SM4_WRITEMASK_SHIFT; + break; + + case VKD3D_SM4_SWIZZLE_VEC4: + swizzle = swizzle_from_sm4((token & VKD3D_SM4_SWIZZLE_MASK) >> VKD3D_SM4_SWIZZLE_SHIFT); + if (swizzle != VKD3D_SHADER_NO_SWIZZLE) + { + FIXME("Unhandled swizzle %#x.\n", swizzle); + vkd3d_shader_parser_warning(&priv->p, VKD3D_SHADER_WARNING_TPF_UNHANDLED_REGISTER_SWIZZLE, + "Unhandled destination register swizzle %#x.", swizzle); + } + dst_param->write_mask = VKD3DSP_WRITEMASK_ALL; + break; + + default: + FIXME("Unhandled swizzle type %#x.\n", swizzle_type); + vkd3d_shader_parser_error(&priv->p, VKD3D_SHADER_ERROR_TPF_INVALID_REGISTER_SWIZZLE, + "Destination register swizzle type %#x is invalid.", swizzle_type); + break; + } break; default: diff --git a/libs/vkd3d-shader/vkd3d_shader_private.h b/libs/vkd3d-shader/vkd3d_shader_private.h index 3ea6e5b4..eceb2414 100644 --- a/libs/vkd3d-shader/vkd3d_shader_private.h +++ b/libs/vkd3d-shader/vkd3d_shader_private.h @@ -85,6 +85,7 @@ enum vkd3d_shader_error VKD3D_SHADER_WARNING_TPF_MASK_NOT_CONTIGUOUS = 1300, VKD3D_SHADER_WARNING_TPF_UNHANDLED_INDEX_RANGE_MASK = 1301, VKD3D_SHADER_WARNING_TPF_UNHANDLED_REGISTER_MASK = 1302, + VKD3D_SHADER_WARNING_TPF_UNHANDLED_REGISTER_SWIZZLE = 1303, VKD3D_SHADER_ERROR_SPV_DESCRIPTOR_BINDING_NOT_FOUND = 2000, VKD3D_SHADER_ERROR_SPV_INVALID_REGISTER_TYPE = 2001,
1
0
0
0
Conor McCarthy : vkd3d-shader/tpf: Handle the dimension bitfield in dst param tokens.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: vkd3d Branch: master Commit: eddae47062124cd25ec6f67337e6a51197bbb8fb URL:
https://gitlab.winehq.org/wine/vkd3d/-/commit/eddae47062124cd25ec6f67337e6a…
Author: Conor McCarthy <cmccarthy(a)codeweavers.com> Date: Tue Aug 8 12:23:43 2023 +1000 vkd3d-shader/tpf: Handle the dimension bitfield in dst param tokens. A zero mask is still emitted for some scalar registers. This has no effect on current tests, but keeping the correction is probably a good idea. --- libs/vkd3d-shader/tpf.c | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/libs/vkd3d-shader/tpf.c b/libs/vkd3d-shader/tpf.c index 084b0bfd..2fcda112 100644 --- a/libs/vkd3d-shader/tpf.c +++ b/libs/vkd3d-shader/tpf.c @@ -2112,6 +2112,7 @@ static bool shader_sm4_read_dst_param(struct vkd3d_shader_sm4_parser *priv, cons const uint32_t *end, enum vkd3d_data_type data_type, struct vkd3d_shader_dst_param *dst_param) { enum vkd3d_shader_src_modifier modifier; + unsigned int dimension; DWORD token; if (*ptr >= end) @@ -2133,10 +2134,30 @@ static bool shader_sm4_read_dst_param(struct vkd3d_shader_sm4_parser *priv, cons return false; } - dst_param->write_mask = (token & VKD3D_SM4_WRITEMASK_MASK) >> VKD3D_SM4_WRITEMASK_SHIFT; + switch ((dimension = (token & VKD3D_SM4_DIMENSION_MASK) >> VKD3D_SM4_DIMENSION_SHIFT)) + { + case VKD3D_SM4_DIMENSION_NONE: + dst_param->write_mask = 0; + break; + + case VKD3D_SM4_DIMENSION_SCALAR: + dst_param->write_mask = VKD3DSP_WRITEMASK_0; + break; + + case VKD3D_SM4_DIMENSION_VEC4: + dst_param->write_mask = (token & VKD3D_SM4_WRITEMASK_MASK) >> VKD3D_SM4_WRITEMASK_SHIFT; + break; + + default: + FIXME("Unhandled dimension %#x.\n", dimension); + vkd3d_shader_parser_error(&priv->p, VKD3D_SHADER_ERROR_TPF_INVALID_REGISTER_DIMENSION, + "Destination register dimension %#x is invalid.", dimension); + break; + } + if (data_type == VKD3D_DATA_DOUBLE) dst_param->write_mask = vkd3d_write_mask_64_from_32(dst_param->write_mask); - /* Scalar registers are declared with no write mask in shader bytecode. */ + /* Some scalar registers are declared with no write mask in shader bytecode. */ if (!dst_param->write_mask && shader_sm4_is_scalar_register(&dst_param->reg)) dst_param->write_mask = VKD3DSP_WRITEMASK_0; dst_param->modifiers = 0;
1
0
0
0
Conor McCarthy : vkd3d-shader/tpf: Use the default vec4 swizzle if a src param contains a mask.
by Alexandre Julliard
28 Aug '23
28 Aug '23
Module: vkd3d Branch: master Commit: 92021b7a3c13143165144cfe045b10030597ab1c URL:
https://gitlab.winehq.org/wine/vkd3d/-/commit/92021b7a3c13143165144cfe045b1…
Author: Conor McCarthy <cmccarthy(a)codeweavers.com> Date: Tue Aug 8 12:09:10 2023 +1000 vkd3d-shader/tpf: Use the default vec4 swizzle if a src param contains a mask. --- libs/vkd3d-shader/spirv.c | 5 ----- libs/vkd3d-shader/tpf.c | 25 +++++++++++++++++++------ libs/vkd3d-shader/vkd3d_shader_private.h | 6 ++++++ 3 files changed, 25 insertions(+), 11 deletions(-) diff --git a/libs/vkd3d-shader/spirv.c b/libs/vkd3d-shader/spirv.c index f1644587..d79796bc 100644 --- a/libs/vkd3d-shader/spirv.c +++ b/libs/vkd3d-shader/spirv.c @@ -204,11 +204,6 @@ static inline bool register_is_undef(const struct vkd3d_shader_register *reg) return reg->type == VKD3DSPR_UNDEF; } -static inline bool register_is_constant(const struct vkd3d_shader_register *reg) -{ - return (reg->type == VKD3DSPR_IMMCONST || reg->type == VKD3DSPR_IMMCONST64); -} - static inline bool register_is_constant_or_undef(const struct vkd3d_shader_register *reg) { return register_is_constant(reg) || register_is_undef(reg); diff --git a/libs/vkd3d-shader/tpf.c b/libs/vkd3d-shader/tpf.c index e00dfd5e..084b0bfd 100644 --- a/libs/vkd3d-shader/tpf.c +++ b/libs/vkd3d-shader/tpf.c @@ -507,7 +507,7 @@ enum vkd3d_sm4_input_primitive_type enum vkd3d_sm4_swizzle_type { - VKD3D_SM4_SWIZZLE_NONE = 0x0, + VKD3D_SM4_SWIZZLE_NONE = 0x0, /* swizzle bitfield contains a mask */ VKD3D_SM4_SWIZZLE_VEC4 = 0x1, VKD3D_SM4_SWIZZLE_SCALAR = 0x2, }; @@ -2026,7 +2026,7 @@ static bool shader_sm4_validate_input_output_register(struct vkd3d_shader_sm4_pa static bool shader_sm4_read_src_param(struct vkd3d_shader_sm4_parser *priv, const uint32_t **ptr, const uint32_t *end, enum vkd3d_data_type data_type, struct vkd3d_shader_src_param *src_param) { - unsigned int dimension; + unsigned int dimension, mask; DWORD token; if (*ptr >= end) @@ -2057,10 +2057,23 @@ static bool shader_sm4_read_src_param(struct vkd3d_shader_sm4_parser *priv, cons switch (swizzle_type) { case VKD3D_SM4_SWIZZLE_NONE: - if (shader_sm4_is_scalar_register(&src_param->reg)) - src_param->swizzle = VKD3D_SHADER_SWIZZLE(X, X, X, X); - else - src_param->swizzle = VKD3D_SHADER_NO_SWIZZLE; + src_param->swizzle = VKD3D_SHADER_NO_SWIZZLE; + + mask = (token & VKD3D_SM4_WRITEMASK_MASK) >> VKD3D_SM4_WRITEMASK_SHIFT; + /* Mask seems only to be used for vec4 constants and is always zero. */ + if (!register_is_constant(&src_param->reg)) + { + FIXME("Source mask %#x is not for a constant.\n", mask); + vkd3d_shader_parser_warning(&priv->p, VKD3D_SHADER_WARNING_TPF_UNHANDLED_REGISTER_MASK, + "Unhandled mask %#x for a non-constant source register.", mask); + } + else if (mask) + { + FIXME("Unhandled mask %#x.\n", mask); + vkd3d_shader_parser_warning(&priv->p, VKD3D_SHADER_WARNING_TPF_UNHANDLED_REGISTER_MASK, + "Unhandled source register mask %#x.", mask); + } + break; case VKD3D_SM4_SWIZZLE_SCALAR: diff --git a/libs/vkd3d-shader/vkd3d_shader_private.h b/libs/vkd3d-shader/vkd3d_shader_private.h index c6be6f22..3ea6e5b4 100644 --- a/libs/vkd3d-shader/vkd3d_shader_private.h +++ b/libs/vkd3d-shader/vkd3d_shader_private.h @@ -84,6 +84,7 @@ enum vkd3d_shader_error VKD3D_SHADER_WARNING_TPF_MASK_NOT_CONTIGUOUS = 1300, VKD3D_SHADER_WARNING_TPF_UNHANDLED_INDEX_RANGE_MASK = 1301, + VKD3D_SHADER_WARNING_TPF_UNHANDLED_REGISTER_MASK = 1302, VKD3D_SHADER_ERROR_SPV_DESCRIPTOR_BINDING_NOT_FOUND = 2000, VKD3D_SHADER_ERROR_SPV_INVALID_REGISTER_TYPE = 2001, @@ -1018,6 +1019,11 @@ static inline bool vkd3d_shader_register_is_patch_constant(const struct vkd3d_sh return reg->type == VKD3DSPR_PATCHCONST; } +static inline bool register_is_constant(const struct vkd3d_shader_register *reg) +{ + return (reg->type == VKD3DSPR_IMMCONST || reg->type == VKD3DSPR_IMMCONST64); +} + struct vkd3d_shader_location { const char *source_name;
1
0
0
0
← Newer
1
...
9
10
11
12
13
14
15
...
67
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
Results per page:
10
25
50
100
200