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
July
June
May
April
March
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
November 2022
----- 2025 -----
July 2025
June 2025
May 2025
April 2025
March 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
1171 discussions
Start a n
N
ew thread
Alex Henrie : advapi32/tests: Avoid using GCC's typeof extension.
by Alexandre Julliard
22 Nov '22
22 Nov '22
Module: wine Branch: master Commit: d2ad82c87e104f01f7c1d74a60ebae1a0ec1cd67 URL:
https://gitlab.winehq.org/wine/wine/-/commit/d2ad82c87e104f01f7c1d74a60ebae…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Mon Nov 21 19:42:45 2022 -0700 advapi32/tests: Avoid using GCC's typeof extension. --- dlls/advapi32/tests/perf.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/dlls/advapi32/tests/perf.c b/dlls/advapi32/tests/perf.c index 34b6e952842..7481020dd4e 100644 --- a/dlls/advapi32/tests/perf.c +++ b/dlls/advapi32/tests/perf.c @@ -31,12 +31,10 @@ #include "initguid.h" -#define DEFINE_FUNCTION(name) static typeof(name) *p##name; -DEFINE_FUNCTION(PerfCloseQueryHandle); -DEFINE_FUNCTION(PerfOpenQueryHandle); -DEFINE_FUNCTION(PerfAddCounters); -DEFINE_FUNCTION(PerfQueryCounterData); -#undef DEFINE_FUNCTION +ULONG (WINAPI *pPerfCloseQueryHandle)(HANDLE); +ULONG (WINAPI *pPerfOpenQueryHandle)(const WCHAR*, HANDLE*); +ULONG (WINAPI *pPerfAddCounters)(HANDLE, PERF_COUNTER_IDENTIFIER*, DWORD); +ULONG (WINAPI *pPerfQueryCounterData)(HANDLE, PERF_DATA_HEADER*, DWORD, DWORD*); static void init_functions(void) {
1
0
0
0
Alex Henrie : windows.media.speech: Put the calling convention inside the function pointer parentheses.
by Alexandre Julliard
22 Nov '22
22 Nov '22
Module: wine Branch: master Commit: abf14cd4bc641b17b3801c141743cbc95e47e580 URL:
https://gitlab.winehq.org/wine/wine/-/commit/abf14cd4bc641b17b3801c141743cb…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Mon Nov 21 20:56:41 2022 -0700 windows.media.speech: Put the calling convention inside the function pointer parentheses. As required by MSVC. --- dlls/windows.media.speech/tests/speech.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/windows.media.speech/tests/speech.c b/dlls/windows.media.speech/tests/speech.c index 464faaf819a..445d10923ae 100644 --- a/dlls/windows.media.speech/tests/speech.c +++ b/dlls/windows.media.speech/tests/speech.c @@ -57,7 +57,7 @@ #define IAsyncHandler_IInspectable_iface IAsyncOperationCompletedHandler_IInspectable_iface -HRESULT WINAPI (*pDllGetActivationFactory)(HSTRING, IActivationFactory **); +HRESULT (WINAPI *pDllGetActivationFactory)(HSTRING, IActivationFactory **); static BOOL is_win10_1507 = FALSE; static BOOL is_win10_1709 = FALSE;
1
0
0
0
Alex Henrie : explorer: Put the calling convention inside the function pointer parentheses.
by Alexandre Julliard
22 Nov '22
22 Nov '22
Module: wine Branch: master Commit: dab61cdcd1f0ddbe6c096ccfe9344d4d33572f22 URL:
https://gitlab.winehq.org/wine/wine/-/commit/dab61cdcd1f0ddbe6c096ccfe9344d…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Mon Nov 21 21:06:37 2022 -0700 explorer: Put the calling convention inside the function pointer parentheses. As required by MSVC. --- programs/explorer/startmenu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/programs/explorer/startmenu.c b/programs/explorer/startmenu.c index 3173ae21fc6..b46bd068220 100644 --- a/programs/explorer/startmenu.c +++ b/programs/explorer/startmenu.c @@ -371,8 +371,8 @@ static void fill_menu(struct menu_item* item) static void run_dialog(void) { - void WINAPI (*pRunFileDlg)(HWND hWndOwner, HICON hIcon, LPCSTR lpszDir, - LPCSTR lpszTitle, LPCSTR lpszDesc, DWORD dwFlags); + void (WINAPI *pRunFileDlg)(HWND owner, HICON icon, const char *dir, + const char *title, const char *desc, DWORD flags); HMODULE hShell32; hShell32 = LoadLibraryW(L"shell32");
1
0
0
0
Alex Henrie : kernel32/tests: Avoid using GCC's typeof extension.
by Alexandre Julliard
22 Nov '22
22 Nov '22
Module: wine Branch: master Commit: 318d02723cef8e79e7b559d569808a98629dc88e URL:
https://gitlab.winehq.org/wine/wine/-/commit/318d02723cef8e79e7b559d569808a…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Mon Nov 21 21:14:47 2022 -0700 kernel32/tests: Avoid using GCC's typeof extension. --- dlls/kernel32/tests/heap.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/dlls/kernel32/tests/heap.c b/dlls/kernel32/tests/heap.c index 3e861f52248..f449f06270d 100644 --- a/dlls/kernel32/tests/heap.c +++ b/dlls/kernel32/tests/heap.c @@ -52,13 +52,10 @@ static BOOLEAN (WINAPI *pRtlSetUserFlagsHeap)(HANDLE,ULONG,void*,ULONG,ULONG); static HGLOBAL (WINAPI *pGlobalAlloc)(UINT,SIZE_T); static HGLOBAL (WINAPI *pGlobalFree)(HGLOBAL); static HGLOBAL (WINAPI *pLocalFree)(HLOCAL); - -#define MAKE_FUNC(f) static typeof(f) *p ## f -MAKE_FUNC( HeapQueryInformation ); -MAKE_FUNC( HeapSetInformation ); -MAKE_FUNC( GlobalFlags ); -MAKE_FUNC( RtlGetNtGlobalFlags ); -#undef MAKE_FUNC +static BOOL (WINAPI *pHeapQueryInformation)(HANDLE,HEAP_INFORMATION_CLASS,void*,SIZE_T,SIZE_T*); +static BOOL (WINAPI *pHeapSetInformation)(HANDLE,HEAP_INFORMATION_CLASS,void*,SIZE_T); +static UINT (WINAPI *pGlobalFlags)(HGLOBAL); +static ULONG (WINAPI *pRtlGetNtGlobalFlags)(void); static void load_functions(void) {
1
0
0
0
Alex Henrie : dinput/tests: Put the calling convention inside the function pointer parentheses.
by Alexandre Julliard
22 Nov '22
22 Nov '22
Module: wine Branch: master Commit: 929de48426eecedcb7730cd7c095f0051cf48551 URL:
https://gitlab.winehq.org/wine/wine/-/commit/929de48426eecedcb7730cd7c095f0…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Mon Nov 21 19:53:18 2022 -0700 dinput/tests: Put the calling convention inside the function pointer parentheses. --- dlls/dinput/tests/force_feedback.c | 10 +++++----- dlls/dinput/tests/hotplug.c | 8 ++++---- dlls/dinput/tests/joystick8.c | 10 +++++----- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/dlls/dinput/tests/force_feedback.c b/dlls/dinput/tests/force_feedback.c index ba37320e9f0..a2ccdb08350 100644 --- a/dlls/dinput/tests/force_feedback.c +++ b/dlls/dinput/tests/force_feedback.c @@ -48,11 +48,11 @@ #include "windows.gaming.input.forcefeedback.h" #undef Size -static HRESULT WINAPI (*pRoGetActivationFactory)( HSTRING, REFIID, void** ); -static HRESULT WINAPI (*pRoInitialize)( RO_INIT_TYPE ); -static HRESULT WINAPI (*pWindowsCreateString)( const WCHAR*, UINT32, HSTRING* ); -static HRESULT WINAPI (*pWindowsDeleteString)( HSTRING str ); -static const WCHAR* WINAPI (*pWindowsGetStringRawBuffer)( HSTRING, UINT32* ); +static HRESULT (WINAPI *pRoGetActivationFactory)( HSTRING, REFIID, void** ); +static HRESULT (WINAPI *pRoInitialize)( RO_INIT_TYPE ); +static HRESULT (WINAPI *pWindowsCreateString)( const WCHAR*, UINT32, HSTRING* ); +static HRESULT (WINAPI *pWindowsDeleteString)( HSTRING str ); +static const WCHAR* (WINAPI *pWindowsGetStringRawBuffer)( HSTRING, UINT32* ); static BOOL load_combase_functions(void) { diff --git a/dlls/dinput/tests/hotplug.c b/dlls/dinput/tests/hotplug.c index e915d04745a..78e38b1e285 100644 --- a/dlls/dinput/tests/hotplug.c +++ b/dlls/dinput/tests/hotplug.c @@ -50,10 +50,10 @@ #include "windows.gaming.input.custom.h" #undef Size -static HRESULT WINAPI (*pRoGetActivationFactory)( HSTRING, REFIID, void** ); -static HRESULT WINAPI (*pRoInitialize)( RO_INIT_TYPE ); -static HRESULT WINAPI (*pWindowsCreateString)( const WCHAR*, UINT32, HSTRING* ); -static HRESULT WINAPI (*pWindowsDeleteString)( HSTRING str ); +static HRESULT (WINAPI *pRoGetActivationFactory)( HSTRING, REFIID, void** ); +static HRESULT (WINAPI *pRoInitialize)( RO_INIT_TYPE ); +static HRESULT (WINAPI *pWindowsCreateString)( const WCHAR*, UINT32, HSTRING* ); +static HRESULT (WINAPI *pWindowsDeleteString)( HSTRING str ); static BOOL load_combase_functions(void) { diff --git a/dlls/dinput/tests/joystick8.c b/dlls/dinput/tests/joystick8.c index f568c9298c6..49f7c1a201e 100644 --- a/dlls/dinput/tests/joystick8.c +++ b/dlls/dinput/tests/joystick8.c @@ -47,11 +47,11 @@ #include "windows.gaming.input.h" #undef Size -static HRESULT WINAPI (*pRoGetActivationFactory)( HSTRING, REFIID, void** ); -static HRESULT WINAPI (*pRoInitialize)( RO_INIT_TYPE ); -static HRESULT WINAPI (*pWindowsCreateString)( const WCHAR*, UINT32, HSTRING* ); -static HRESULT WINAPI (*pWindowsDeleteString)( HSTRING str ); -static const WCHAR* WINAPI (*pWindowsGetStringRawBuffer)( HSTRING, UINT32* ); +static HRESULT (WINAPI *pRoGetActivationFactory)( HSTRING, REFIID, void** ); +static HRESULT (WINAPI *pRoInitialize)( RO_INIT_TYPE ); +static HRESULT (WINAPI *pWindowsCreateString)( const WCHAR*, UINT32, HSTRING* ); +static HRESULT (WINAPI *pWindowsDeleteString)( HSTRING str ); +static const WCHAR* (WINAPI *pWindowsGetStringRawBuffer)( HSTRING, UINT32* ); static BOOL load_combase_functions(void) {
1
0
0
0
Alex Henrie : webservices: Remove unused function heap_realloc_zero.
by Alexandre Julliard
22 Nov '22
22 Nov '22
Module: wine Branch: master Commit: 78e0caa5ef09a4410b5b72d841746079c57e3973 URL:
https://gitlab.winehq.org/wine/wine/-/commit/78e0caa5ef09a4410b5b72d8417460…
Author: Alex Henrie <alexhenrie24(a)gmail.com> Date: Mon Nov 21 22:44:25 2022 -0700 webservices: Remove unused function heap_realloc_zero. This function has not been used since commit 105d16774432a6ab206896404ca644d9ee7e2b7e. --- dlls/webservices/webservices_private.h | 5 ----- 1 file changed, 5 deletions(-) diff --git a/dlls/webservices/webservices_private.h b/dlls/webservices/webservices_private.h index 478f1aa00f3..e488614c2a5 100644 --- a/dlls/webservices/webservices_private.h +++ b/dlls/webservices/webservices_private.h @@ -406,8 +406,3 @@ static inline BOOL is_valid_parent( const struct node *node ) if (!node) return FALSE; return (node_type( node ) == WS_XML_NODE_TYPE_ELEMENT || node_type( node ) == WS_XML_NODE_TYPE_BOF); } - -static inline void* __WINE_ALLOC_SIZE(2) heap_realloc_zero(void *mem, size_t size) -{ - return HeapReAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, mem, size); -}
1
0
0
0
Gabriel Ivăncescu : jscript: Use CRT allocation functions.
by Alexandre Julliard
21 Nov '22
21 Nov '22
Module: wine Branch: master Commit: ae73e09a8d071eaa33fafe785e8295384b9e64a7 URL:
https://gitlab.winehq.org/wine/wine/-/commit/ae73e09a8d071eaa33fafe785e8295…
Author: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> Date: Mon Nov 21 20:43:43 2022 +0200 jscript: Use CRT allocation functions. Signed-off-by: Gabriel Ivăncescu <gabrielopcode(a)gmail.com> --- dlls/jscript/array.c | 18 +++++++++--------- dlls/jscript/bool.c | 4 ++-- dlls/jscript/compile.c | 40 ++++++++++++++++++++-------------------- dlls/jscript/date.c | 16 ++++++++-------- dlls/jscript/engine.c | 18 +++++++++--------- dlls/jscript/enumerator.c | 6 +++--- dlls/jscript/error.c | 4 ++-- dlls/jscript/function.c | 34 +++++++++++++++++----------------- dlls/jscript/jscript.c | 2 +- dlls/jscript/jscript.h | 1 - dlls/jscript/json.c | 26 +++++++++++++------------- dlls/jscript/jsregexp.c | 18 +++++++++--------- dlls/jscript/jsstr.c | 10 +++++----- dlls/jscript/jsutils.c | 26 +++++++++++++------------- dlls/jscript/lex.c | 8 ++++---- dlls/jscript/math.c | 4 ++-- dlls/jscript/number.c | 4 ++-- dlls/jscript/object.c | 6 +++--- dlls/jscript/parser.y | 4 ++-- dlls/jscript/regexp.c | 30 +++++++++++++++--------------- dlls/jscript/regexp.h | 2 +- dlls/jscript/set.c | 12 ++++++------ dlls/jscript/string.c | 22 +++++++++++----------- dlls/jscript/vbarray.c | 12 ++++++------ 24 files changed, 163 insertions(+), 164 deletions(-)
1
0
0
0
Matthew Tran : hid: Fix HidP_(Get|Set)(Scaled)UsageValue with usage ranges and arrays.
by Alexandre Julliard
21 Nov '22
21 Nov '22
Module: wine Branch: master Commit: a08eb8969a2267f90e1f6948b68b62d0375a1efd URL:
https://gitlab.winehq.org/wine/wine/-/commit/a08eb8969a2267f90e1f6948b68b62…
Author: Matthew Tran <0e4ef622(a)gmail.com> Date: Mon Nov 21 12:47:34 2022 +0100 hid: Fix HidP_(Get|Set)(Scaled)UsageValue with usage ranges and arrays. --- dlls/dinput/tests/hid.c | 12 ------------ dlls/hid/hidp.c | 36 ++++++++++++++++++++++-------------- 2 files changed, 22 insertions(+), 26 deletions(-)
1
0
0
0
Rémi Bernon : hid: Move (get|set)_usage_value around and use it for scaled values.
by Alexandre Julliard
21 Nov '22
21 Nov '22
Module: wine Branch: master Commit: 7f6e8387dd5cabaae759d39bf54a8ca2bcc72853 URL:
https://gitlab.winehq.org/wine/wine/-/commit/7f6e8387dd5cabaae759d39bf54a8c…
Author: Rémi Bernon <rbernon(a)codeweavers.com> Date: Mon Nov 21 12:43:23 2022 +0100 hid: Move (get|set)_usage_value around and use it for scaled values. --- dlls/hid/hidp.c | 80 +++++++++++++++++++++++++++------------------------------ 1 file changed, 38 insertions(+), 42 deletions(-) diff --git a/dlls/hid/hidp.c b/dlls/hid/hidp.c index a1c5805c19f..bf5a6259484 100644 --- a/dlls/hid/hidp.c +++ b/dlls/hid/hidp.c @@ -236,18 +236,33 @@ static LONG sign_extend( ULONG value, const struct hid_value_caps *caps ) return value - ((value & sign) << 1); } -static NTSTATUS get_scaled_usage_value( const struct hid_value_caps *caps, void *user ) +static NTSTATUS get_usage_value( const struct hid_value_caps *caps, void *user ) { struct usage_value_params *params = user; - ULONG unsigned_value = 0, bit_count = caps->bit_size * caps->report_count; - LONG signed_value, *value = params->value_buf; + ULONG bit_count = caps->bit_size * caps->report_count; unsigned char *report_buf; - if ((bit_count + 7) / 8 > sizeof(unsigned_value)) return HIDP_STATUS_BUFFER_TOO_SMALL; - if (sizeof(LONG) > params->value_len) return HIDP_STATUS_BUFFER_TOO_SMALL; + if ((bit_count + 7) / 8 > params->value_len) return HIDP_STATUS_BUFFER_TOO_SMALL; + memset( params->value_buf, 0, params->value_len ); report_buf = (unsigned char *)params->report_buf + caps->start_byte; - copy_bits( (unsigned char *)&unsigned_value, report_buf, bit_count, -caps->start_bit ); + copy_bits( params->value_buf, report_buf, bit_count, -caps->start_bit ); + + return HIDP_STATUS_NULL; +} + +static NTSTATUS get_scaled_usage_value( const struct hid_value_caps *caps, void *user ) +{ + struct usage_value_params *params = user; + LONG signed_value, *value = params->value_buf; + ULONG unsigned_value = 0; + NTSTATUS status; + + params->value_buf = &unsigned_value; + params->value_len = sizeof(unsigned_value); + if ((status = get_usage_value( caps, params )) != HIDP_STATUS_NULL) return status; + + if (sizeof(LONG) > params->value_len) return HIDP_STATUS_BUFFER_TOO_SMALL; signed_value = sign_extend( unsigned_value, caps ); if (caps->logical_min > caps->logical_max || caps->physical_min > caps->physical_max) @@ -280,21 +295,6 @@ NTSTATUS WINAPI HidP_GetScaledUsageValue( HIDP_REPORT_TYPE report_type, USAGE us return enum_value_caps( preparsed, report_type, report_len, &filter, get_scaled_usage_value, ¶ms, &count ); } -static NTSTATUS get_usage_value( const struct hid_value_caps *caps, void *user ) -{ - struct usage_value_params *params = user; - ULONG bit_count = caps->bit_size * caps->report_count; - unsigned char *report_buf; - - if ((bit_count + 7) / 8 > params->value_len) return HIDP_STATUS_BUFFER_TOO_SMALL; - memset( params->value_buf, 0, params->value_len ); - - report_buf = (unsigned char *)params->report_buf + caps->start_byte; - copy_bits( params->value_buf, report_buf, bit_count, -caps->start_bit ); - - return HIDP_STATUS_NULL; -} - NTSTATUS WINAPI HidP_GetUsageValue( HIDP_REPORT_TYPE report_type, USAGE usage_page, USHORT collection, USAGE usage, ULONG *value, PHIDP_PREPARSED_DATA preparsed_data, char *report_buf, ULONG report_len ) { @@ -446,17 +446,28 @@ ULONG WINAPI HidP_MaxUsageListLength( HIDP_REPORT_TYPE report_type, USAGE usage_ return count; } -static NTSTATUS set_scaled_usage_value( const struct hid_value_caps *caps, void *user ) +static NTSTATUS set_usage_value( const struct hid_value_caps *caps, void *user ) { - ULONG bit_count = caps->bit_size * caps->report_count; struct usage_value_params *params = user; + ULONG bit_count = caps->bit_size * caps->report_count; unsigned char *report_buf; + + if ((bit_count + 7) / 8 > params->value_len) return HIDP_STATUS_BUFFER_TOO_SMALL; + + report_buf = (unsigned char *)params->report_buf + caps->start_byte; + copy_bits( report_buf, params->value_buf, bit_count, caps->start_bit ); + + return HIDP_STATUS_NULL; +} + +static NTSTATUS set_scaled_usage_value( const struct hid_value_caps *caps, void *user ) +{ + struct usage_value_params *params = user; LONG value, log_range, phy_range; if (caps->logical_min > caps->logical_max) return HIDP_STATUS_BAD_LOG_PHY_VALUES; if (caps->physical_min > caps->physical_max) return HIDP_STATUS_BAD_LOG_PHY_VALUES; - if ((bit_count + 7) / 8 > sizeof(value)) return HIDP_STATUS_BUFFER_TOO_SMALL; if (sizeof(LONG) > params->value_len) return HIDP_STATUS_BUFFER_TOO_SMALL; value = *(LONG *)params->value_buf; @@ -471,10 +482,9 @@ static NTSTATUS set_scaled_usage_value( const struct hid_value_caps *caps, void value = caps->logical_min + value; } - report_buf = (unsigned char *)params->report_buf + caps->start_byte; - copy_bits( report_buf, (unsigned char *)&value, bit_count, caps->start_bit ); - - return HIDP_STATUS_NULL; + params->value_buf = &value; + params->value_len = sizeof(value); + return set_usage_value( caps, params ); } NTSTATUS WINAPI HidP_SetScaledUsageValue( HIDP_REPORT_TYPE report_type, USAGE usage_page, USHORT collection, @@ -495,20 +505,6 @@ NTSTATUS WINAPI HidP_SetScaledUsageValue( HIDP_REPORT_TYPE report_type, USAGE us return enum_value_caps( preparsed, report_type, report_len, &filter, set_scaled_usage_value, ¶ms, &count ); } -static NTSTATUS set_usage_value( const struct hid_value_caps *caps, void *user ) -{ - struct usage_value_params *params = user; - ULONG bit_count = caps->bit_size * caps->report_count; - unsigned char *report_buf; - - if ((bit_count + 7) / 8 > params->value_len) return HIDP_STATUS_BUFFER_TOO_SMALL; - - report_buf = (unsigned char *)params->report_buf + caps->start_byte; - copy_bits( report_buf, params->value_buf, bit_count, caps->start_bit ); - - return HIDP_STATUS_NULL; -} - NTSTATUS WINAPI HidP_SetUsageValue( HIDP_REPORT_TYPE report_type, USAGE usage_page, USHORT collection, USAGE usage, ULONG value, PHIDP_PREPARSED_DATA preparsed_data, char *report_buf, ULONG report_len ) {
1
0
0
0
Matthew Tran : winexinput.sys: Fix incorrect HID STRING_INDEX tag value.
by Alexandre Julliard
21 Nov '22
21 Nov '22
Module: wine Branch: master Commit: 84f44de79fa9af56ac7f22e0d7d6e8786ec1d102 URL:
https://gitlab.winehq.org/wine/wine/-/commit/84f44de79fa9af56ac7f22e0d7d6e8…
Author: Matthew Tran <0e4ef622(a)gmail.com> Date: Sun Nov 20 01:10:59 2022 -0600 winexinput.sys: Fix incorrect HID STRING_INDEX tag value. --- dlls/winexinput.sys/psh_hid_macros.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dlls/winexinput.sys/psh_hid_macros.h b/dlls/winexinput.sys/psh_hid_macros.h index 4623af20598..8e0a2a9dd6b 100644 --- a/dlls/winexinput.sys/psh_hid_macros.h +++ b/dlls/winexinput.sys/psh_hid_macros.h @@ -79,7 +79,7 @@ #define DESIGNATOR_INDEX(n,data) SHORT_ITEM_##n(0x3,2,data) #define DESIGNATOR_MINIMUM(n,data) SHORT_ITEM_##n(0x4,2,data) #define DESIGNATOR_MAXIMUM(n,data) SHORT_ITEM_##n(0x5,2,data) -#define STRING_INDEX(n,data) SHORT_ITEM_##n(0x6,2,data) -#define STRING_MINIMUM(n,data) SHORT_ITEM_##n(0x7,2,data) -#define STRING_MAXIMUM(n,data) SHORT_ITEM_##n(0x8,2,data) -#define DELIMITER(n,data) SHORT_ITEM_##n(0x9,2,data) +#define STRING_INDEX(n,data) SHORT_ITEM_##n(0x7,2,data) +#define STRING_MINIMUM(n,data) SHORT_ITEM_##n(0x8,2,data) +#define STRING_MAXIMUM(n,data) SHORT_ITEM_##n(0x9,2,data) +#define DELIMITER(n,data) SHORT_ITEM_##n(0xa,2,data)
1
0
0
0
← Newer
1
...
37
38
39
40
41
42
43
...
118
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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
Results per page:
10
25
50
100
200