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
February 2020
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
874 discussions
Start a n
N
ew thread
Tag wine-5.2 : Alexandre Julliard : Release 5.2
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: refs/tags/wine-5.2 Tag: 77e6a3fd8aeda295b44bc3b86a6ec493bdd36a11 URL:
https://source.winehq.org/git/wine.git/?a=tag;h=77e6a3fd8aeda295b44bc3b86a6…
Tagger: Alexandre Julliard <julliard(a)winehq.org> Date: Sun Feb 16 22:21:52 2020 +0100 Release 5.2
1
0
0
0
Alexandre Julliard : Release 5.2.
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: 85bd94f8705115ac0c35eac6ff7e2f3e59be924e URL:
https://source.winehq.org/git/wine.git/?a=commit;h=85bd94f8705115ac0c35eac6…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Sun Feb 16 22:21:52 2020 +0100 Release 5.2. Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- .mailmap | 1 + ANNOUNCE | 1007 ++++++++++++++++++++++++++++++++----------------------------- AUTHORS | 2 + VERSION | 2 +- configure | 18 +- 5 files changed, 550 insertions(+), 480 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=85bd94f8705115ac0c35…
1
0
0
0
Matteo Bruni : d3dcompiler/tests: Make test_reflection_constant_buffer() work on d3d10.
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: d4682017d60d2ca13282cc5aae33f54ed224781a URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d4682017d60d2ca13282cc5a…
Author: Matteo Bruni <mbruni(a)codeweavers.com> Date: Fri Feb 14 19:31:04 2020 +0100 d3dcompiler/tests: Make test_reflection_constant_buffer() work on d3d10. Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dcompiler_43/tests/reflection.c | 147 +++++++++++++++++++++++++++++---- 1 file changed, 131 insertions(+), 16 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=d4682017d60d2ca13282…
1
0
0
0
Matteo Bruni : d3dcompiler: Free variable definitions data on allocation errors.
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: 4e8ec8a6e0ffc55bf636840f5a37b0717b014d0a URL:
https://source.winehq.org/git/wine.git/?a=commit;h=4e8ec8a6e0ffc55bf636840f…
Author: Matteo Bruni <mbruni(a)codeweavers.com> Date: Fri Feb 14 19:31:03 2020 +0100 d3dcompiler: Free variable definitions data on allocation errors. Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dcompiler_43/hlsl.y | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/dlls/d3dcompiler_43/hlsl.y b/dlls/d3dcompiler_43/hlsl.y index 52b2b6310b..b6478bf3fe 100644 --- a/dlls/d3dcompiler_43/hlsl.y +++ b/dlls/d3dcompiler_43/hlsl.y @@ -530,6 +530,15 @@ static void struct_var_initializer(struct list *list, struct hlsl_ir_var *var, d3dcompiler_free(initializer->args); } +static void free_parse_variable_def(struct parse_variable_def *v) +{ + free_parse_initializer(&v->initializer); + d3dcompiler_free(v->name); + d3dcompiler_free((void *)v->semantic); + d3dcompiler_free(v->reg_reservation); + d3dcompiler_free(v); +} + static struct list *declare_vars(struct hlsl_type *basic_type, DWORD modifiers, struct list *var_list) { struct hlsl_type *type; @@ -543,7 +552,7 @@ static struct list *declare_vars(struct hlsl_type *basic_type, DWORD modifiers, { ERR("Out of memory.\n"); LIST_FOR_EACH_ENTRY_SAFE(v, v_next, var_list, struct parse_variable_def, entry) - d3dcompiler_free(v); + free_parse_variable_def(v); d3dcompiler_free(var_list); return NULL; } @@ -558,7 +567,7 @@ static struct list *declare_vars(struct hlsl_type *basic_type, DWORD modifiers, if (!var) { ERR("Out of memory.\n"); - d3dcompiler_free(v); + free_parse_variable_def(v); continue; } if (v->array_size)
1
0
0
0
Jacek Caban : ucrtbase: Use public headers for _vsnprintf implementation.
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: 18545725b1156745a98a9af31a1a485452211ce8 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=18545725b1156745a98a9af3…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Fri Feb 14 15:40:59 2020 +0100 ucrtbase: Use public headers for _vsnprintf implementation. Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/ucrtbase/printf.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/dlls/ucrtbase/printf.c b/dlls/ucrtbase/printf.c index 099026950f..6a1e5fdea7 100644 --- a/dlls/ucrtbase/printf.c +++ b/dlls/ucrtbase/printf.c @@ -21,15 +21,14 @@ #pragma makedep implib #endif -#define _CRTIMP #include <stdarg.h> -#include "msvcrt.h" +#include <corecrt_stdio_config.h> -int __cdecl __stdio_common_vsprintf(unsigned __int64 options, char *str, MSVCRT_size_t len, - const char *format, MSVCRT__locale_t locale, __ms_va_list valist); +int __cdecl __stdio_common_vsprintf(unsigned __int64 options, char *str, size_t len, + const char *format, _locale_t locale, __ms_va_list valist); -int __cdecl _vsnprintf( char *buf, MSVCRT_size_t size, const char *fmt, __ms_va_list args ) +int __cdecl _vsnprintf( char *buf, size_t size, const char *fmt, __ms_va_list args ) { - return __stdio_common_vsprintf( UCRTBASE_PRINTF_STANDARD_SNPRINTF_BEHAVIOUR, + return __stdio_common_vsprintf( _CRT_INTERNAL_LOCAL_PRINTF_OPTIONS | _CRT_INTERNAL_PRINTF_STANDARD_SNPRINTF_BEHAVIOR, buf, size, fmt, NULL, args ); }
1
0
0
0
Jacek Caban : include: Move NULL define to corecrt.h.
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: d840af4b872cf3ed10b122902a68ba1756be8e25 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d840af4b872cf3ed10b12290…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Fri Feb 14 15:40:50 2020 +0100 include: Move NULL define to corecrt.h. Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- include/msvcrt/corecrt.h | 8 ++++++++ include/msvcrt/stddef.h | 8 -------- include/msvcrt/stdio.h | 8 -------- include/msvcrt/stdlib.h | 8 -------- include/msvcrt/string.h | 8 -------- include/msvcrt/time.h | 8 -------- include/msvcrt/wchar.h | 8 -------- 7 files changed, 8 insertions(+), 48 deletions(-) diff --git a/include/msvcrt/corecrt.h b/include/msvcrt/corecrt.h index 38acf8512e..cff4549d37 100644 --- a/include/msvcrt/corecrt.h +++ b/include/msvcrt/corecrt.h @@ -41,6 +41,14 @@ # endif #endif +#ifndef NULL +#ifdef __cplusplus +#define NULL 0 +#else +#define NULL ((void *)0) +#endif +#endif + #ifndef __stdcall # ifdef __i386__ # ifdef __GNUC__ diff --git a/include/msvcrt/stddef.h b/include/msvcrt/stddef.h index 052132ed71..12025d53dc 100644 --- a/include/msvcrt/stddef.h +++ b/include/msvcrt/stddef.h @@ -20,14 +20,6 @@ #include <corecrt.h> -#ifndef NULL -#ifdef __cplusplus -#define NULL 0 -#else -#define NULL ((void *)0) -#endif -#endif - #ifdef __GNUC__ #define offsetof(s,m) __builtin_offsetof(s,m) #elif defined(_WIN64) diff --git a/include/msvcrt/stdio.h b/include/msvcrt/stdio.h index ecaa7fe611..8a31835bea 100644 --- a/include/msvcrt/stdio.h +++ b/include/msvcrt/stdio.h @@ -19,14 +19,6 @@ #define _IOSTRG 0x0040 #define _IORW 0x0080 -#ifndef NULL -#ifdef __cplusplus -#define NULL 0 -#else -#define NULL ((void *)0) -#endif -#endif - #define STDIN_FILENO 0 #define STDOUT_FILENO 1 #define STDERR_FILENO 2 diff --git a/include/msvcrt/stdlib.h b/include/msvcrt/stdlib.h index 91fcc2a672..78fc5fba75 100644 --- a/include/msvcrt/stdlib.h +++ b/include/msvcrt/stdlib.h @@ -12,14 +12,6 @@ #include <pshpack8.h> -#ifndef NULL -#ifdef __cplusplus -#define NULL 0 -#else -#define NULL ((void*)0) -#endif -#endif - typedef struct { float f; diff --git a/include/msvcrt/string.h b/include/msvcrt/string.h index 96421cb491..f8bc40fb2a 100644 --- a/include/msvcrt/string.h +++ b/include/msvcrt/string.h @@ -15,14 +15,6 @@ #define _NLSCMP_DEFINED #endif -#ifndef NULL -#ifdef __cplusplus -#define NULL 0 -#else -#define NULL ((void *)0) -#endif -#endif - #ifdef __cplusplus extern "C" { #endif diff --git a/include/msvcrt/time.h b/include/msvcrt/time.h index d55e8bbf81..9ed27f5f9e 100644 --- a/include/msvcrt/time.h +++ b/include/msvcrt/time.h @@ -29,14 +29,6 @@ typedef __msvcrt_long clock_t; #define _CLOCK_T_DEFINED #endif -#ifndef NULL -#ifdef __cplusplus -#define NULL 0 -#else -#define NULL ((void *)0) -#endif -#endif - #ifndef CLOCKS_PER_SEC #define CLOCKS_PER_SEC 1000 #endif diff --git a/include/msvcrt/wchar.h b/include/msvcrt/wchar.h index 1fcbaa9399..119f8a2a41 100644 --- a/include/msvcrt/wchar.h +++ b/include/msvcrt/wchar.h @@ -17,14 +17,6 @@ extern "C" { #endif -#ifndef NULL -#ifdef __cplusplus -#define NULL 0 -#else -#define NULL ((void *)0) -#endif -#endif - #ifndef WCHAR_MIN /* also in stdint.h */ #define WCHAR_MIN 0U #define WCHAR_MAX 0xffffU
1
0
0
0
Jacek Caban : corecrt_stdio_config.h: Add new header file.
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: 44c863bec4c568ef2be6250c01db053fd44b4b7c URL:
https://source.winehq.org/git/wine.git/?a=commit;h=44c863bec4c568ef2be6250c…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Fri Feb 14 15:40:43 2020 +0100 corecrt_stdio_config.h: Add new header file. Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- include/Makefile.in | 1 + include/msvcrt/corecrt_stdio_config.h | 30 ++++++++++++++++++++++++++++++ include/msvcrt/corecrt_wstdio.h | 1 + 3 files changed, 32 insertions(+) diff --git a/include/Makefile.in b/include/Makefile.in index 6a822273a9..0e5dd475e0 100644 --- a/include/Makefile.in +++ b/include/Makefile.in @@ -423,6 +423,7 @@ SOURCES = \ msvcrt/assert.h \ msvcrt/conio.h \ msvcrt/corecrt.h \ + msvcrt/corecrt_stdio_config.h \ msvcrt/corecrt_wstdio.h \ msvcrt/crtdbg.h \ msvcrt/crtdefs.h \ diff --git a/include/msvcrt/corecrt_stdio_config.h b/include/msvcrt/corecrt_stdio_config.h new file mode 100644 index 0000000000..02a83684f8 --- /dev/null +++ b/include/msvcrt/corecrt_stdio_config.h @@ -0,0 +1,30 @@ +/** + * This file has no copyright assigned and is placed in the Public Domain. + * This file is part of the Wine project. + * No warranty is given; refer to the file DISCLAIMER.PD within this package. + */ + +#ifndef _STDIO_CONFIG_DEFINED +#define _STDIO_CONFIG_DEFINED + +#include <corecrt.h> + +#define _CRT_INTERNAL_PRINTF_LEGACY_VSPRINTF_NULL_TERMINATION 0x0001ULL +#define _CRT_INTERNAL_PRINTF_STANDARD_SNPRINTF_BEHAVIOR 0x0002ULL +#define _CRT_INTERNAL_PRINTF_LEGACY_WIDE_SPECIFIERS 0x0004ULL +#define _CRT_INTERNAL_PRINTF_LEGACY_MSVCRT_COMPATIBILITY 0x0008ULL +#define _CRT_INTERNAL_PRINTF_LEGACY_THREE_DIGIT_EXPONENTS 0x0010ULL + +#define _CRT_INTERNAL_SCANF_SECURECRT 0x0001ULL +#define _CRT_INTERNAL_SCANF_LEGACY_WIDE_SPECIFIERS 0x0002ULL +#define _CRT_INTERNAL_SCANF_LEGACY_MSVCRT_COMPATIBILITY 0x0004ULL + +#ifndef _CRT_INTERNAL_LOCAL_PRINTF_OPTIONS +#define _CRT_INTERNAL_LOCAL_PRINTF_OPTIONS _CRT_INTERNAL_PRINTF_LEGACY_WIDE_SPECIFIERS +#endif + +#ifndef _CRT_INTERNAL_LOCAL_SCANF_OPTIONS +#define _CRT_INTERNAL_LOCAL_SCANF_OPTIONS _CRT_INTERNAL_SCANF_LEGACY_WIDE_SPECIFIERS +#endif + +#endif /* _STDIO_CONFIG_DEFINED */ diff --git a/include/msvcrt/corecrt_wstdio.h b/include/msvcrt/corecrt_wstdio.h index 488d2c4ae6..1480d32bf6 100644 --- a/include/msvcrt/corecrt_wstdio.h +++ b/include/msvcrt/corecrt_wstdio.h @@ -8,6 +8,7 @@ #define _WSTDIO_DEFINED #include <corecrt.h> +#include <corecrt_stdio_config.h> #ifndef RC_INVOKED #include <stdarg.h>
1
0
0
0
Jacek Caban : stdio.h: Provide sprintf and _snprintf as inline wrappers.
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: 84dbedc922dbfea6f8a0a562e9fb6142bc58f9da URL:
https://source.winehq.org/git/wine.git/?a=commit;h=84dbedc922dbfea6f8a0a562…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Fri Feb 14 13:07:24 2020 +0100 stdio.h: Provide sprintf and _snprintf as inline wrappers. It's enough for Wine debug functions to use _vsnprintf from ucrtbase importlib instead of ntdll for modules that link to ucrtbase. Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/msvcp90/msvcp_main.c | 10 ---------- include/msvcrt/stdio.h | 24 ++++++++++++++++++++++-- 2 files changed, 22 insertions(+), 12 deletions(-) diff --git a/dlls/msvcp90/msvcp_main.c b/dlls/msvcp90/msvcp_main.c index 6166591d0c..b6375f71dc 100644 --- a/dlls/msvcp90/msvcp_main.c +++ b/dlls/msvcp90/msvcp_main.c @@ -124,16 +124,6 @@ int WINAPIV _scprintf(const char* fmt, ...) __ms_va_end(valist); return ret; } - -int WINAPIV sprintf(char *buf, const char *fmt, ...) -{ - int ret; - __ms_va_list valist; - __ms_va_start(valist, fmt); - ret = _vsnprintf(buf, -1, fmt, valist); - __ms_va_end(valist); - return ret; -} #endif static void init_cxx_funcs(void) diff --git a/include/msvcrt/stdio.h b/include/msvcrt/stdio.h index d01e788f80..ecaa7fe611 100644 --- a/include/msvcrt/stdio.h +++ b/include/msvcrt/stdio.h @@ -98,7 +98,6 @@ int __cdecl _putw(int,FILE*); int __cdecl _rmtmp(void); int __cdecl _set_printf_count_output(int); int __cdecl _setmaxstdio(int); -int WINAPIV _snprintf(char*,size_t,const char*,...); int WINAPIV _snprintf_s(char*,size_t,size_t,const char*,...); char* __cdecl _tempnam(const char*,const char*); int __cdecl _unlink(const char*); @@ -165,7 +164,6 @@ int WINAPIV scanf(const char*,...); int WINAPIV scanf_s(const char*,...); void __cdecl setbuf(FILE*,char*); int __cdecl setvbuf(FILE*,char*,int,size_t); -int WINAPIV sprintf(char*,const char*,...); int WINAPIV sprintf_s(char*,size_t,const char*,...); int WINAPIV _scprintf(const char *, ...); int WINAPIV sscanf(const char*,const char*,...); @@ -204,6 +202,28 @@ static inline int unlink(const char* path) { return _unlink(path); } static inline int vsnprintf(char *buffer, size_t size, const char *format, __ms_va_list args) { return _vsnprintf(buffer,size,format,args); } #define snprintf _snprintf +static inline int WINAPIV _snprintf(char *buffer, size_t size, const char *format, ...) +{ + int ret; + __ms_va_list args; + + __ms_va_start(args, format); + ret = _vsnprintf(buffer, size, format, args); + __ms_va_end(args); + return ret; +} + +static inline int WINAPIV sprintf(char *buffer, const char *format, ...) +{ + int ret; + __ms_va_list args; + + __ms_va_start(args, format); + ret = _vsnprintf(buffer, (size_t)-1, format, args); + __ms_va_end(args); + return ret; +} + static inline wint_t fgetwchar(void) { return _fgetwchar(); } static inline wint_t fputwchar(wint_t wc) { return _fputwchar(wc); } static inline int getw(FILE* file) { return _getw(file); }
1
0
0
0
Michael Stefaniuc : dmime: Implement IDirectMusicPerformance8_PChannelInfo().
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: d3a0cd77d8c87f9fcf56958e7db01bbd07a60f09 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d3a0cd77d8c87f9fcf56958e…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Fri Feb 14 01:21:07 2020 +0100 dmime: Implement IDirectMusicPerformance8_PChannelInfo(). Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dmime/performance.c | 27 +++++++++++++++++++-------- dlls/dmime/tests/performance.c | 32 +++++++++++++++----------------- 2 files changed, 34 insertions(+), 25 deletions(-) diff --git a/dlls/dmime/performance.c b/dlls/dmime/performance.c index 989e5ee207..b7b71637a1 100644 --- a/dlls/dmime/performance.c +++ b/dlls/dmime/performance.c @@ -725,18 +725,29 @@ static HRESULT WINAPI IDirectMusicPerformance8Impl_AssignPChannel(IDirectMusicPe } static HRESULT WINAPI IDirectMusicPerformance8Impl_PChannelInfo(IDirectMusicPerformance8 *iface, - DWORD PChannel, IDirectMusicPort **port, DWORD *group, DWORD *MChannel) + DWORD pchannel, IDirectMusicPort **port, DWORD *group, DWORD *channel) { IDirectMusicPerformance8Impl *This = impl_from_IDirectMusicPerformance8(iface); - DMUS_PORTPARAMS8 port_params; - GUID default_port; + struct pchannel_block *block; + struct wine_rb_entry *entry; + DWORD block_num = pchannel / 16; + unsigned int index = pchannel % 16; + + TRACE("(%p)->(%d, %p, %p, %p)\n", This, pchannel, port, group, channel); - FIXME("(%p)->(%d, %p, %p, %p): stub\n", This, PChannel, port, group, MChannel); + entry = wine_rb_get(&This->pchannels, &block_num); + if (!entry) + return E_INVALIDARG; + block = WINE_RB_ENTRY_VALUE(entry, struct pchannel_block, entry); - port_params.dwSize = sizeof(DMUS_PORTPARAMS8); - port_params.dwValidParams = 0; - IDirectMusic8_GetDefaultPort(This->dmusic, &default_port); - IDirectMusic8_CreatePort(This->dmusic, &default_port, &port_params, port, NULL); + if (port) { + *port = block->pchannel[index].port; + IDirectMusicPort_AddRef(*port); + } + if (group) + *group = block->pchannel[index].group; + if (channel) + *channel = block->pchannel[index].channel; return S_OK; } diff --git a/dlls/dmime/tests/performance.c b/dlls/dmime/tests/performance.c index 97c43c520b..825faabc9c 100644 --- a/dlls/dmime/tests/performance.c +++ b/dlls/dmime/tests/performance.c @@ -102,11 +102,12 @@ static HRESULT test_InitAudio(void) return hr; } - port = NULL; hr = IDirectMusicPerformance8_PChannelInfo(performance, 128, &port, NULL, NULL); - todo_wine ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x\n", hr); + ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x\n", hr); hr = IDirectMusicPerformance8_PChannelInfo(performance, 127, &port, NULL, NULL); ok(hr == S_OK, "PChannelInfo failed, got %08x\n", hr); + IDirectMusicPort_Release(port); + port = NULL; hr = IDirectMusicPerformance8_PChannelInfo(performance, 0, &port, NULL, NULL); ok(hr == S_OK, "PChannelInfo failed, got %08x\n", hr); ok(port != NULL, "IDirectMusicPort not set\n"); @@ -114,8 +115,7 @@ static HRESULT test_InitAudio(void) todo_wine ok(hr == DMUS_E_AUDIOPATHS_IN_USE, "AssignPChannel failed (%08x)\n", hr); hr = IDirectMusicPerformance8_AssignPChannelBlock(performance, 0, port, 0); todo_wine ok(hr == DMUS_E_AUDIOPATHS_IN_USE, "AssignPChannelBlock failed (%08x)\n", hr); - if (port) - IDirectMusicPort_Release(port); + IDirectMusicPort_Release(port); hr = IDirectMusicPerformance8_GetDefaultAudioPath(performance, &path); ok(hr == S_OK, "Failed to call GetDefaultAudioPath (%x)\n", hr); @@ -132,7 +132,7 @@ static HRESULT test_InitAudio(void) hr = IDirectMusicPerformance8_InitAudio(performance, NULL, NULL, NULL, 0, 64, 0, NULL); ok(hr == S_OK, "InitAudio failed: %08x\n", hr); hr = IDirectMusicPerformance8_PChannelInfo(performance, 0, &port, NULL, NULL); - todo_wine ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x\n", hr); + ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x\n", hr); destroy_performance(performance, NULL, NULL); /* Refcounts for auto generated dmusic and dsound */ @@ -223,10 +223,10 @@ static HRESULT test_InitAudio(void) DMUS_APATH_SHARED_STEREOPLUSREVERB, 29, DMUS_AUDIOF_ALL, NULL); ok(hr == S_OK, "InitAudio failed: %08x\n", hr); hr = IDirectMusicPerformance8_PChannelInfo(performance, 31, &port, &group, &channel); - todo_wine ok(hr == S_OK && group == 2 && channel == 15, + ok(hr == S_OK && group == 2 && channel == 15, "PChannelInfo failed, got %08x, %u, %u\n", hr, group, channel); hr = IDirectMusicPerformance8_PChannelInfo(performance, 32, &port, NULL, NULL); - todo_wine ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x\n", hr); + ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x\n", hr); destroy_performance(performance, NULL, NULL); return S_OK; @@ -349,7 +349,7 @@ static void test_pchannel(void) hr = IDirectMusicPerformance8_Init(perf, NULL, NULL, NULL); ok(hr == S_OK, "Init failed: %08x\n", hr); hr = IDirectMusicPerformance8_PChannelInfo(perf, 0, &port, NULL, NULL); - todo_wine ok(hr == E_INVALIDARG && !port, "PChannelInfo failed, got %08x, %p\n", hr, port); + ok(hr == E_INVALIDARG && !port, "PChannelInfo failed, got %08x, %p\n", hr, port); /* Add default port. Sets PChannels 0-15 to the corresponding channels in group 1 */ hr = IDirectMusicPerformance8_AddPort(perf, NULL); @@ -360,18 +360,16 @@ static void test_pchannel(void) ok(hr == S_OK && port, "PChannelInfo failed, got %08x, %p\n", hr, port); for (i = 1; i < 16; i++) { hr = IDirectMusicPerformance8_PChannelInfo(perf, i, &port2, &group, &channel); - todo_wine ok(hr == S_OK && port == port2 && group == 1 && channel == i, + ok(hr == S_OK && port == port2 && group == 1 && channel == i, "PChannelInfo failed, got %08x, %p, %u, %u\n", hr, port2, group, channel); IDirectMusicPort_Release(port2); } /* Unset PChannels fail to retrieve */ - todo_wine { hr = IDirectMusicPerformance8_PChannelInfo(perf, 16, &port2, NULL, NULL); ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x, %p\n", hr, port); hr = IDirectMusicPerformance8_PChannelInfo(perf, MAXDWORD - 16, &port2, NULL, NULL); ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x, %p\n", hr, port); - } /* Channel group 0 can be set just fine */ hr = IDirectMusicPerformance8_AssignPChannel(perf, 0, port, 0, 0); @@ -380,7 +378,7 @@ static void test_pchannel(void) ok(hr == S_OK, "AssignPChannelBlock failed, got %08x\n", hr); for (i = 1; i < 16; i++) { hr = IDirectMusicPerformance8_PChannelInfo(perf, i, &port2, &group, &channel); - todo_wine ok(hr == S_OK && port == port2 && group == 0 && channel == i, + ok(hr == S_OK && port == port2 && group == 0 && channel == i, "PChannelInfo failed, got %08x, %p, %u, %u\n", hr, port2, group, channel); IDirectMusicPort_Release(port2); } @@ -411,7 +409,7 @@ static void test_pchannel(void) hr = IDirectMusicPerformance8_AssignPChannel(perf, i, port, 1, 7); ok(hr == S_OK, "AssignPChannel failed, got %08x\n", hr); hr = IDirectMusicPerformance8_PChannelInfo(perf, i, &port2, &group, &channel); - todo_wine ok(hr == S_OK && port2 == port && group == 1 && channel == 7, + ok(hr == S_OK && port2 == port && group == 1 && channel == 7, "PChannelInfo failed, got %08x, %p, %u, %u\n", hr, port2, group, channel); IDirectMusicPort_Release(port2); } @@ -421,7 +419,7 @@ static void test_pchannel(void) ok(hr == S_OK, "AssignPChannelBlock failed, got %08x\n", hr); for (i = MAXDWORD - 47; i < MAXDWORD - 31; i++) { hr = IDirectMusicPerformance8_PChannelInfo(perf, i, &port2, &group, &channel); - todo_wine ok(hr == S_OK && port2 == port && group == 0 && channel == i % 16, + ok(hr == S_OK && port2 == port && group == 0 && channel == i % 16, "PChannelInfo failed, got %08x, %p, %u, %u\n", hr, port2, group, channel); IDirectMusicPort_Release(port2); } @@ -430,17 +428,17 @@ static void test_pchannel(void) hr = IDirectMusicPerformance8_AssignPChannel(perf, 4711, port, 1, 13); ok(hr == S_OK, "AssignPChannel failed, got %08x\n", hr); hr = IDirectMusicPerformance8_PChannelInfo(perf, 4711, &port2, &group, &channel); - todo_wine ok(hr == S_OK && port2 == port && group == 1 && channel == 13, + ok(hr == S_OK && port2 == port && group == 1 && channel == 13, "PChannelInfo failed, got %08x, %p, %u, %u\n", hr, port2, group, channel); IDirectMusicPort_Release(port2); group = channel = 0xdeadbeef; hr = IDirectMusicPerformance8_PChannelInfo(perf, 4712, &port2, &group, &channel); - todo_wine ok(hr == S_OK && port2 == port && group == 0 && channel == 8, + ok(hr == S_OK && port2 == port && group == 0 && channel == 8, "PChannelInfo failed, got %08x, %p, %u, %u\n", hr, port2, group, channel); IDirectMusicPort_Release(port2); group = channel = 0xdeadbeef; hr = IDirectMusicPerformance8_PChannelInfo(perf, 4719, &port2, &group, &channel); - todo_wine ok(hr == S_OK && port2 == port && group == 0 && channel == 15, + ok(hr == S_OK && port2 == port && group == 0 && channel == 15, "PChannelInfo failed, got %08x, %p, %u, %u\n", hr, port2, group, channel); IDirectMusicPort_Release(port2);
1
0
0
0
Michael Stefaniuc : dmime: Create a port in the perf CreateStandardAudioPath().
by Alexandre Julliard
16 Feb '20
16 Feb '20
Module: wine Branch: master Commit: 3dd2912874c9beb0e62c03b43a45788df7222d21 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=3dd2912874c9beb0e62c03b4…
Author: Michael Stefaniuc <mstefani(a)winehq.org> Date: Fri Feb 14 01:21:06 2020 +0100 dmime: Create a port in the perf CreateStandardAudioPath(). Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dmime/performance.c | 13 ++++++++++--- dlls/dmime/tests/performance.c | 13 +++++++++++++ 2 files changed, 23 insertions(+), 3 deletions(-) diff --git a/dlls/dmime/performance.c b/dlls/dmime/performance.c index b12247ea31..989e5ee207 100644 --- a/dlls/dmime/performance.c +++ b/dlls/dmime/performance.c @@ -1070,16 +1070,17 @@ static HRESULT WINAPI IDirectMusicPerformance8Impl_CreateAudioPath(IDirectMusicP } static HRESULT WINAPI IDirectMusicPerformance8Impl_CreateStandardAudioPath(IDirectMusicPerformance8 *iface, - DWORD dwType, DWORD dwPChannelCount, BOOL fActivate, IDirectMusicAudioPath **ppNewPath) + DWORD dwType, DWORD pchannel_count, BOOL fActivate, IDirectMusicAudioPath **ppNewPath) { IDirectMusicPerformance8Impl *This = impl_from_IDirectMusicPerformance8(iface); IDirectMusicAudioPath *pPath; DSBUFFERDESC desc; WAVEFORMATEX format; + DMUS_PORTPARAMS params = {0}; IDirectSoundBuffer *buffer, *primary_buffer; HRESULT hr = S_OK; - FIXME("(%p)->(%d, %d, %d, %p): semi-stub\n", This, dwType, dwPChannelCount, fActivate, ppNewPath); + FIXME("(%p)->(%d, %d, %d, %p): semi-stub\n", This, dwType, pchannel_count, fActivate, ppNewPath); if (NULL == ppNewPath) { return E_POINTER; @@ -1126,7 +1127,13 @@ static HRESULT WINAPI IDirectMusicPerformance8Impl_CreateStandardAudioPath(IDire return E_INVALIDARG; } - /* FIXME: Should we create one secondary buffer for each PChannel? */ + /* Create a port */ + params.dwValidParams = DMUS_PORTPARAMS_CHANNELGROUPS | DMUS_PORTPARAMS_AUDIOCHANNELS; + params.dwChannelGroups = (pchannel_count + 15) / 16; + params.dwAudioChannels = format.nChannels; + if (FAILED(hr = perf_dmport_create(This, ¶ms))) + return hr; + hr = IDirectSound_CreateSoundBuffer(This->dsound, &desc, &buffer, NULL); if (FAILED(hr)) return DSERR_BUFFERLOST; diff --git a/dlls/dmime/tests/performance.c b/dlls/dmime/tests/performance.c index ff275eb9c2..97c43c520b 100644 --- a/dlls/dmime/tests/performance.c +++ b/dlls/dmime/tests/performance.c @@ -82,6 +82,7 @@ static HRESULT test_InitAudio(void) IDirectSound *dsound; IDirectMusicPort *port; IDirectMusicAudioPath *path; + DWORD channel, group; HRESULT hr; ULONG ref; @@ -216,6 +217,18 @@ static HRESULT test_InitAudio(void) ok(ref == 2, "dmusic ref count got %d expected 2\n", ref); destroy_performance(performance, dmusic, dsound); + /* InitAudio with perf channel count not a multiple of 16 rounds up */ + create_performance(&performance, NULL, NULL, TRUE); + hr = IDirectMusicPerformance8_InitAudio(performance, NULL, NULL, NULL, + DMUS_APATH_SHARED_STEREOPLUSREVERB, 29, DMUS_AUDIOF_ALL, NULL); + ok(hr == S_OK, "InitAudio failed: %08x\n", hr); + hr = IDirectMusicPerformance8_PChannelInfo(performance, 31, &port, &group, &channel); + todo_wine ok(hr == S_OK && group == 2 && channel == 15, + "PChannelInfo failed, got %08x, %u, %u\n", hr, group, channel); + hr = IDirectMusicPerformance8_PChannelInfo(performance, 32, &port, NULL, NULL); + todo_wine ok(hr == E_INVALIDARG, "PChannelInfo failed, got %08x\n", hr); + destroy_performance(performance, NULL, NULL); + return S_OK; }
1
0
0
0
← Newer
1
...
36
37
38
39
40
41
42
...
88
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
Results per page:
10
25
50
100
200