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 2022
----- 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
1495 discussions
Start a n
N
ew thread
Eric Pouech : usbd.sys: Enable compilation with long types.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: b9c3bdea88413c8deeb720f4c7f05253456745a5 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=b9c3bdea88413c8deeb720f4…
Author: Eric Pouech <eric.pouech(a)gmail.com> Date: Mon Feb 21 07:57:32 2022 +0100 usbd.sys: Enable compilation with long types. Signed-off-by: Eric Pouech <eric.pouech(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/usbd.sys/Makefile.in | 1 - dlls/usbd.sys/usbd.c | 6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/dlls/usbd.sys/Makefile.in b/dlls/usbd.sys/Makefile.in index 026f4ba4219..6040071ddaf 100644 --- a/dlls/usbd.sys/Makefile.in +++ b/dlls/usbd.sys/Makefile.in @@ -1,4 +1,3 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES MODULE = usbd.sys IMPORTLIB = usbd IMPORTS = ntoskrnl diff --git a/dlls/usbd.sys/usbd.c b/dlls/usbd.sys/usbd.c index 1cb25259258..d562cf1f81e 100644 --- a/dlls/usbd.sys/usbd.c +++ b/dlls/usbd.sys/usbd.c @@ -173,7 +173,7 @@ PUSB_INTERFACE_DESCRIPTOR WINAPI USBD_ParseConfigurationDescriptorEx( PUSB_INTERFACE_DESCRIPTOR interface; - TRACE( "(%p, %p, %d, %d, %d, %d, %d)\n", ConfigurationDescriptor, + TRACE( "(%p, %p, %ld, %ld, %ld, %ld, %ld)\n", ConfigurationDescriptor, StartPosition, InterfaceNumber, AlternateSetting, InterfaceClass, InterfaceSubClass, InterfaceProtocol ); @@ -214,7 +214,7 @@ PUSB_COMMON_DESCRIPTOR WINAPI USBD_ParseDescriptors( { PUSB_COMMON_DESCRIPTOR common; - TRACE( "(%p, %u, %p, %d)\n", DescriptorBuffer, TotalLength, StartPosition, DescriptorType ); + TRACE( "(%p, %lu, %p, %ld)\n", DescriptorBuffer, TotalLength, StartPosition, DescriptorType ); for (common = (PUSB_COMMON_DESCRIPTOR)DescriptorBuffer; ((char*)common) + sizeof(USB_COMMON_DESCRIPTOR) <= ((char*)DescriptorBuffer) + TotalLength; @@ -233,7 +233,7 @@ USBD_STATUS WINAPI USBD_ValidateConfigurationDescriptor( PUCHAR *offset, ULONG tag ) { - FIXME( "(%p, %u, %u, %p, %u) partial stub!\n", descr, length, level, offset, tag ); + FIXME( "(%p, %lu, %u, %p, %lu) partial stub!\n", descr, length, level, offset, tag ); if (offset) *offset = 0;
1
0
0
0
Nikolay Sivov : t2embed/tests: Build without -DWINE_NO_LONG_TYPES.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: 30a418c34e3a01ab519e8b1600995ff0b3ff20e9 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=30a418c34e3a01ab519e8b16…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Feb 20 21:04:06 2022 +0300 t2embed/tests: Build without -DWINE_NO_LONG_TYPES. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/t2embed/tests/Makefile.in | 1 - dlls/t2embed/tests/t2embed.c | 54 ++++++++++++++++++++++-------------------- 2 files changed, 28 insertions(+), 27 deletions(-) diff --git a/dlls/t2embed/tests/Makefile.in b/dlls/t2embed/tests/Makefile.in index 69d91384869..c4f49a3f6ca 100644 --- a/dlls/t2embed/tests/Makefile.in +++ b/dlls/t2embed/tests/Makefile.in @@ -1,4 +1,3 @@ -EXTRADEFS = -DWINE_NO_LONG_TYPES TESTDLL = t2embed.dll IMPORTS = user32 gdi32 t2embed diff --git a/dlls/t2embed/tests/t2embed.c b/dlls/t2embed/tests/t2embed.c index 4ffc3daed12..004ba5492ae 100644 --- a/dlls/t2embed/tests/t2embed.c +++ b/dlls/t2embed/tests/t2embed.c @@ -43,7 +43,7 @@ static int CALLBACK enum_font_proc(ENUMLOGFONTEXA *enumlf, NEWTEXTMETRICEXA *ntm UINT fsType = otm.otmfsType & 0xf; ret = TTGetEmbeddingType(hdc, &status); - ok(ret == E_NONE || ret == E_NOTATRUETYPEFONT, "Unexpected return value %#x.\n", ret); + ok(ret == E_NONE || ret == E_NOTATRUETYPEFONT, "Unexpected return value %#lx.\n", ret); if (ret == E_NONE) { @@ -56,7 +56,7 @@ static int CALLBACK enum_font_proc(ENUMLOGFONTEXA *enumlf, NEWTEXTMETRICEXA *ntm else if (fsType & LICENSE_NOEMBEDDING) expected = EMBED_NOEMBEDDING; - ok(expected == status, "%s: status %d, expected %d, fsType %#x\n", enumlf->elfLogFont.lfFaceName, status, + ok(expected == status, "%s: status %ld, expected %ld, fsType %#x\n", enumlf->elfLogFont.lfFaceName, status, expected, otm.otmfsType); } } @@ -64,8 +64,8 @@ static int CALLBACK enum_font_proc(ENUMLOGFONTEXA *enumlf, NEWTEXTMETRICEXA *ntm { status = 0xdeadbeef; ret = TTGetEmbeddingType(hdc, &status); - ok(ret == E_NOTATRUETYPEFONT, "%s: got %d\n", enumlf->elfLogFont.lfFaceName, ret); - ok(status == 0xdeadbeef, "%s: got status %d\n", enumlf->elfLogFont.lfFaceName, status); + ok(ret == E_NOTATRUETYPEFONT, "%s: got %ld.\n", enumlf->elfLogFont.lfFaceName, ret); + ok(status == 0xdeadbeef, "%s: got status %#lx.\n", enumlf->elfLogFont.lfFaceName, status); } SelectObject(hdc, old_font); @@ -84,27 +84,28 @@ static void test_TTGetEmbeddingType(void) HDC hdc; ret = TTGetEmbeddingType(NULL, NULL); - ok(ret == E_HDCINVALID, "got %d\n", ret); + ok(ret == E_HDCINVALID, "Unexpected retval %#lx.\n", ret); status = 0xdeadbeef; ret = TTGetEmbeddingType(NULL, &status); - ok(ret == E_HDCINVALID, "got %#x\n", ret); - ok(status == 0xdeadbeef, "got %u\n", status); + ok(ret == E_HDCINVALID, "Unexpected retval %#lx.\n", ret); + ok(status == 0xdeadbeef, "Unexpected status %#lx.\n", status); status = 0xdeadbeef; ret = TTGetEmbeddingType((HDC)0xdeadbeef, &status); - ok(ret == E_NOTATRUETYPEFONT || broken(ret == E_ERRORACCESSINGFONTDATA) /* xp, vista */, "got %#x\n", ret); - ok(status == 0xdeadbeef, "got %u\n", status); + ok(ret == E_NOTATRUETYPEFONT || broken(ret == E_ERRORACCESSINGFONTDATA) /* xp, vista */, + "Unexpected retval %#lx.\n", ret); + ok(status == 0xdeadbeef, "Unexpected status %#lx.\n", status); hdc = CreateCompatibleDC(0); ret = TTGetEmbeddingType(hdc, NULL); - ok(ret == E_NOTATRUETYPEFONT, "got %#x\n", ret); + ok(ret == E_NOTATRUETYPEFONT, "Unexpected retval %#lx.\n", ret); status = 0xdeadbeef; ret = TTGetEmbeddingType(hdc, &status); - ok(ret == E_NOTATRUETYPEFONT, "got %#x\n", ret); - ok(status == 0xdeadbeef, "got %u\n", status); + ok(ret == E_NOTATRUETYPEFONT, "Unexpected retval %#lx.\n", ret); + ok(status == 0xdeadbeef, "Unexpected status %#lx.\n", status); memset(&logfont, 0, sizeof(logfont)); logfont.lfHeight = 12; @@ -117,11 +118,11 @@ static void test_TTGetEmbeddingType(void) status = 0; ret = TTGetEmbeddingType(hdc, &status); - ok(ret == E_NONE, "got %#x\n", ret); - ok(status != 0, "got %u\n", status); + ok(ret == E_NONE, "Unexpected retval %#lx.\n", ret); + ok(status != 0, "Unexpected status %lu.\n", status); ret = TTGetEmbeddingType(hdc, NULL); - ok(ret == E_PERMISSIONSINVALID, "got %#x\n", ret); + ok(ret == E_PERMISSIONSINVALID, "Unexpected retval %#lx.\n", ret); SelectObject(hdc, old_font); DeleteObject(hfont); @@ -140,36 +141,37 @@ static void test_TTIsEmbeddingEnabledForFacename(void) LONG ret; ret = TTIsEmbeddingEnabledForFacename(NULL, NULL); - ok(ret == E_FACENAMEINVALID, "got %#x\n", ret); + ok(ret == E_FACENAMEINVALID, "Unexpected retval %#lx.\n", ret); status = 123; ret = TTIsEmbeddingEnabledForFacename(NULL, &status); - ok(ret == E_FACENAMEINVALID, "got %#x\n", ret); + ok(ret == E_FACENAMEINVALID, "Unexpected retval %#lx.\n", ret); ok(status == 123, "got %d\n", status); ret = TTIsEmbeddingEnabledForFacename("Arial", NULL); - ok(ret == E_PBENABLEDINVALID, "got %#x\n", ret); + ok(ret == E_PBENABLEDINVALID, "Unexpected retval %#lx.\n", ret); status = 123; ret = TTIsEmbeddingEnabledForFacename("Arial", &status); - ok(ret == E_NONE, "got %#x\n", ret); + ok(ret == E_NONE, "Unexpected retval %#lx.\n", ret); ok(status != 123, "got %d\n", status); } static void test_TTIsEmbeddingEnabled(void) { HFONT old_font, hfont; - LONG ret, status; LOGFONTA logfont; + BOOL status; + LONG ret; HDC hdc; ret = TTIsEmbeddingEnabled(NULL, NULL); - ok(ret == E_HDCINVALID, "got %#x\n", ret); + ok(ret == E_HDCINVALID, "Unexpected retval %#lx.\n", ret); status = 123; ret = TTIsEmbeddingEnabled(NULL, &status); - ok(ret == E_HDCINVALID, "got %#x\n", ret); - ok(status == 123, "got %d\n", status); + ok(ret == E_HDCINVALID, "Unexpected retval %#lx.\n", ret); + ok(status == 123, "Unexpected status %d.\n", status); hdc = CreateCompatibleDC(0); @@ -183,12 +185,12 @@ static void test_TTIsEmbeddingEnabled(void) old_font = SelectObject(hdc, hfont); ret = TTIsEmbeddingEnabled(hdc, NULL); - ok(ret == E_PBENABLEDINVALID, "Unexpected return value %#x.\n", ret); + ok(ret == E_PBENABLEDINVALID, "Unexpected retval %#lx.\n", ret); status = 123; ret = TTIsEmbeddingEnabled(hdc, &status); - ok(ret == E_NONE, "got %#x\n", ret); - ok(status != 123, "got %u\n", status); + ok(ret == E_NONE, "Unexpected retval %#lx.\n", ret); + ok(status != 123, "Unexpected status %d.\n", status); SelectObject(hdc, old_font); DeleteObject(hfont);
1
0
0
0
Nikolay Sivov : dxva2/tests: Build without -DWINE_NO_LONG_TYPES.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: f22b55b749bba50b52e4ea710e15bb38ed95e3c5 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=f22b55b749bba50b52e4ea71…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Feb 20 19:31:32 2022 +0300 dxva2/tests: Build without -DWINE_NO_LONG_TYPES. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/dxva2/tests/Makefile.in | 1 - dlls/dxva2/tests/dxva2.c | 182 +++++++++++++++++++++---------------------- 2 files changed, 91 insertions(+), 92 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=f22b55b749bba50b52e4…
1
0
0
0
Nikolay Sivov : shcore/tests: Build without -DWINE_NO_LONG_TYPES.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: f3a87a92e9780e85d42e89c98547a28d98a32c4f URL:
https://source.winehq.org/git/wine.git/?a=commit;h=f3a87a92e9780e85d42e89c9…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Feb 20 19:31:10 2022 +0300 shcore/tests: Build without -DWINE_NO_LONG_TYPES. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/shcore/tests/Makefile.in | 1 - dlls/shcore/tests/shcore.c | 136 +++++++++++++++++++++--------------------- 2 files changed, 68 insertions(+), 69 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=f3a87a92e9780e85d42e…
1
0
0
0
Nikolay Sivov : mfplat: Add VT_R4 case for propvariant tracing.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: 6dc3d258ce69c8ee34f7399ebf0460300f210b0f URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6dc3d258ce69c8ee34f7399e…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Feb 20 18:48:12 2022 +0300 mfplat: Add VT_R4 case for propvariant tracing. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mfplat/mfplat_private.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dlls/mfplat/mfplat_private.h b/dlls/mfplat/mfplat_private.h index dc29545df73..8418c8eb2ef 100644 --- a/dlls/mfplat/mfplat_private.h +++ b/dlls/mfplat/mfplat_private.h @@ -133,6 +133,8 @@ static inline const char *debugstr_propvar(const PROPVARIANT *v) return wine_dbg_sprintf("%p {VT_UI8: %s}", v, wine_dbgstr_longlong(v->uhVal.QuadPart)); case VT_I8: return wine_dbg_sprintf("%p {VT_I8: %s}", v, wine_dbgstr_longlong(v->hVal.QuadPart)); + case VT_R4: + return wine_dbg_sprintf("%p {VT_R4: %.8e}", v, v->fltVal); case VT_R8: return wine_dbg_sprintf("%p {VT_R8: %lf}", v, v->dblVal); case VT_CLSID:
1
0
0
0
Nikolay Sivov : wshom: Implement standard streams properties for Exec object.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: 1128970a757a4b31a531e7c9178a44acec78bbfa URL:
https://source.winehq.org/git/wine.git/?a=commit;h=1128970a757a4b31a531e7c9…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Feb 20 17:09:17 2022 +0300 wshom: Implement standard streams properties for Exec object. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=38210
Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wshom.ocx/shell.c | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) diff --git a/dlls/wshom.ocx/shell.c b/dlls/wshom.ocx/shell.c index d1942c73cea..e04844458b1 100644 --- a/dlls/wshom.ocx/shell.c +++ b/dlls/wshom.ocx/shell.c @@ -230,29 +230,38 @@ static HRESULT WINAPI WshExec_get_Status(IWshExec *iface, WshExecStatus *status) static HRESULT WINAPI WshExec_get_StdIn(IWshExec *iface, ITextStream **stream) { - WshExecImpl *This = impl_from_IWshExec(iface); + WshExecImpl *exec = impl_from_IWshExec(iface); - FIXME("(%p)->(%p): stub\n", This, stream); + TRACE("%p, %p.\n", iface, stream); - return E_NOTIMPL; + *stream = exec->stdin_stream; + ITextStream_AddRef(*stream); + + return S_OK; } static HRESULT WINAPI WshExec_get_StdOut(IWshExec *iface, ITextStream **stream) { - WshExecImpl *This = impl_from_IWshExec(iface); + WshExecImpl *exec = impl_from_IWshExec(iface); - FIXME("(%p)->(%p): stub\n", This, stream); + TRACE("%p, %p.\n", iface, stream); - return E_NOTIMPL; + *stream = exec->stdout_stream; + ITextStream_AddRef(*stream); + + return S_OK; } static HRESULT WINAPI WshExec_get_StdErr(IWshExec *iface, ITextStream **stream) { - WshExecImpl *This = impl_from_IWshExec(iface); + WshExecImpl *exec = impl_from_IWshExec(iface); - FIXME("(%p)->(%p): stub\n", This, stream); + TRACE("%p, %p.\n", iface, stream); - return E_NOTIMPL; + *stream = exec->stderr_stream; + ITextStream_AddRef(*stream); + + return S_OK; } static HRESULT WINAPI WshExec_get_ProcessID(IWshExec *iface, DWORD *pid)
1
0
0
0
Nikolay Sivov : wshom: Create standard streams when starting new process with Exec().
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: a51400101905a21f65151d8ef879348ff5e50942 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a51400101905a21f65151d8e…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Feb 20 17:09:16 2022 +0300 wshom: Create standard streams when starting new process with Exec(). Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/scrrun/Makefile.in | 1 + dlls/wshom.ocx/Makefile.in | 2 +- dlls/wshom.ocx/shell.c | 116 ++++++++++++++++++++++++++++++++++++++++----- 3 files changed, 106 insertions(+), 13 deletions(-) diff --git a/dlls/scrrun/Makefile.in b/dlls/scrrun/Makefile.in index 31ef016f48e..12be899162b 100644 --- a/dlls/scrrun/Makefile.in +++ b/dlls/scrrun/Makefile.in @@ -1,4 +1,5 @@ MODULE = scrrun.dll +IMPORTLIB = scrrun IMPORTS = uuid oleaut32 version advapi32 EXTRADLLFLAGS = -Wb,--prefer-native diff --git a/dlls/wshom.ocx/Makefile.in b/dlls/wshom.ocx/Makefile.in index fed2babda33..1264e9c96a5 100644 --- a/dlls/wshom.ocx/Makefile.in +++ b/dlls/wshom.ocx/Makefile.in @@ -1,5 +1,5 @@ MODULE = wshom.ocx -IMPORTS = uuid oleaut32 ole32 shell32 user32 advapi32 +IMPORTS = uuid oleaut32 ole32 shell32 user32 advapi32 scrrun EXTRADLLFLAGS = -Wb,--prefer-native diff --git a/dlls/wshom.ocx/shell.c b/dlls/wshom.ocx/shell.c index 82d618b1142..d1942c73cea 100644 --- a/dlls/wshom.ocx/shell.c +++ b/dlls/wshom.ocx/shell.c @@ -25,6 +25,8 @@ #include "wine/debug.h" +extern HRESULT WINAPI DoOpenPipeStream(HANDLE pipe, IOMode mode, ITextStream **stream); + WINE_DEFAULT_DEBUG_CHANNEL(wshom); typedef struct @@ -64,6 +66,9 @@ typedef struct IWshExec IWshExec_iface; LONG ref; PROCESS_INFORMATION info; + ITextStream *stdin_stream; + ITextStream *stdout_stream; + ITextStream *stderr_stream; } WshExecImpl; static inline WshCollection *impl_from_IWshCollection( IWshCollection *iface ) @@ -122,14 +127,22 @@ static ULONG WINAPI WshExec_AddRef(IWshExec *iface) static ULONG WINAPI WshExec_Release(IWshExec *iface) { - WshExecImpl *This = impl_from_IWshExec(iface); - LONG ref = InterlockedDecrement(&This->ref); + WshExecImpl *exec = impl_from_IWshExec(iface); + LONG ref = InterlockedDecrement(&exec->ref); + TRACE("%p, refcount %ld.\n", iface, ref); - if (!ref) { - CloseHandle(This->info.hThread); - CloseHandle(This->info.hProcess); - free(This); + if (!ref) + { + CloseHandle(exec->info.hThread); + CloseHandle(exec->info.hProcess); + if (exec->stdin_stream) + ITextStream_Release(exec->stdin_stream); + if (exec->stdout_stream) + ITextStream_Release(exec->stdout_stream); + if (exec->stderr_stream) + ITextStream_Release(exec->stderr_stream); + free(exec); } return ref; @@ -314,10 +327,35 @@ static const IWshExecVtbl WshExecVtbl = { WshExec_Terminate }; +static HRESULT create_pipe(HANDLE *hread, HANDLE *hwrite) +{ + SECURITY_ATTRIBUTES sa; + + sa.nLength = sizeof(sa); + sa.bInheritHandle = TRUE; + sa.lpSecurityDescriptor = NULL; + + *hread = *hwrite = NULL; + if (!CreatePipe(hread, hwrite, &sa, 0)) + return HRESULT_FROM_WIN32(GetLastError()); + return S_OK; +} + +static void close_pipe(HANDLE *hread, HANDLE *hwrite) +{ + CloseHandle(*hread); + CloseHandle(*hwrite); + *hread = *hwrite = NULL; +} + static HRESULT WshExec_create(BSTR command, IWshExec **ret) { + HANDLE stdout_read, stdout_write; + HANDLE stderr_read, stderr_write; + HANDLE stdin_read, stdin_write; STARTUPINFOW si = {0}; WshExecImpl *object; + HRESULT hr; *ret = NULL; @@ -326,17 +364,71 @@ static HRESULT WshExec_create(BSTR command, IWshExec **ret) object->IWshExec_iface.lpVtbl = &WshExecVtbl; object->ref = 1; + init_classinfo(&CLSID_WshExec, (IUnknown *)&object->IWshExec_iface, &object->classinfo); - if (!CreateProcessW(NULL, command, NULL, NULL, FALSE, 0, NULL, NULL, &si, &object->info)) + if (FAILED(hr = create_pipe(&stdin_read, &stdin_write))) { - free(object); - return HRESULT_FROM_WIN32(GetLastError()); + WARN("Failed to create stdin pipe.\n"); + goto failed; } - init_classinfo(&CLSID_WshExec, (IUnknown *)&object->IWshExec_iface, &object->classinfo); - *ret = &object->IWshExec_iface; + if (FAILED(hr = create_pipe(&stdout_read, &stdout_write))) + { + close_pipe(&stdin_read, &stdin_write); + WARN("Failed to create stdout pipe.\n"); + goto failed; + } - return S_OK; + if (FAILED(hr = create_pipe(&stderr_read, &stderr_write))) + { + close_pipe(&stdin_read, &stdin_write); + close_pipe(&stdout_read, &stdout_write); + WARN("Failed to create stderr pipe.\n"); + goto failed; + } + + if (SUCCEEDED(hr)) + { + SetHandleInformation(stdin_write, HANDLE_FLAG_INHERIT, 0); + SetHandleInformation(stdout_read, HANDLE_FLAG_INHERIT, 0); + SetHandleInformation(stderr_read, HANDLE_FLAG_INHERIT, 0); + } + + if (SUCCEEDED(hr)) + hr = DoOpenPipeStream(stdin_write, ForWriting, &object->stdin_stream); + if (SUCCEEDED(hr)) + hr = DoOpenPipeStream(stdout_read, ForReading, &object->stdout_stream); + if (SUCCEEDED(hr)) + hr = DoOpenPipeStream(stderr_read, ForReading, &object->stderr_stream); + + si.cb = sizeof(si); + si.hStdError = stderr_write; + si.hStdOutput = stdout_write; + si.hStdInput = stdin_read; + si.dwFlags = STARTF_USESTDHANDLES; + + if (SUCCEEDED(hr)) + { + if (!CreateProcessW(NULL, command, NULL, NULL, FALSE, 0, NULL, NULL, &si, &object->info)) + hr = HRESULT_FROM_WIN32(GetLastError()); + } + + CloseHandle(stderr_write); + CloseHandle(stdout_write); + CloseHandle(stdin_read); + + if (SUCCEEDED(hr)) + { + *ret = &object->IWshExec_iface; + + return S_OK; + } + +failed: + + IWshExec_Release(&object->IWshExec_iface); + + return hr; } static HRESULT WINAPI WshEnvironment_QueryInterface(IWshEnvironment *iface, REFIID riid, void **obj)
1
0
0
0
Nikolay Sivov : scrrun: Use same write implementation for pipe stream.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: 0faf9c1f065fb220827fef31a3567739bc43097d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=0faf9c1f065fb220827fef31…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Feb 20 17:09:15 2022 +0300 scrrun: Use same write implementation for pipe stream. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/scrrun/filesystem.c | 6 ++++-- dlls/scrrun/tests/filesystem.c | 2 -- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dlls/scrrun/filesystem.c b/dlls/scrrun/filesystem.c index 0e51929ea54..d7ad255e517 100644 --- a/dlls/scrrun/filesystem.c +++ b/dlls/scrrun/filesystem.c @@ -791,9 +791,11 @@ static HRESULT WINAPI pipestream_ReadAll(ITextStream *iface, BSTR *text) static HRESULT WINAPI pipestream_Write(ITextStream *iface, BSTR text) { - FIXME("%p, %s.\n", iface, debugstr_w(text)); + struct textstream *stream = impl_from_ITextStream(iface); - return E_NOTIMPL; + TRACE("%p, %s.\n", iface, debugstr_w(text)); + + return textstream_write(stream, text); } static HRESULT WINAPI pipestream_WriteLine(ITextStream *iface, BSTR text) diff --git a/dlls/scrrun/tests/filesystem.c b/dlls/scrrun/tests/filesystem.c index 894b6251f34..79af87591ff 100644 --- a/dlls/scrrun/tests/filesystem.c +++ b/dlls/scrrun/tests/filesystem.c @@ -2656,11 +2656,9 @@ static void test_DoOpenPipeStream(void) { str = SysAllocString(L"data"); hr = ITextStream_Write(stream_write, str); - todo_wine ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); hr = ITextStream_Write(stream_read, str); - todo_wine ok(hr == CTL_E_BADFILEMODE, "Unexpected hr %#lx.\n", hr); SysFreeString(str);
1
0
0
0
Nikolay Sivov : scrrun: Move IO mode check to writing helper.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: a9c4bda48138627b9f98bda403bea7f7a74e185c URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a9c4bda48138627b9f98bda4…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sun Feb 20 17:09:14 2022 +0300 scrrun: Move IO mode check to writing helper. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/scrrun/filesystem.c | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/dlls/scrrun/filesystem.c b/dlls/scrrun/filesystem.c index 4794437a71d..0e51929ea54 100644 --- a/dlls/scrrun/filesystem.c +++ b/dlls/scrrun/filesystem.c @@ -609,11 +609,14 @@ static HRESULT WINAPI textstream_ReadAll(ITextStream *iface, BSTR *text) return read_from_buffer(This, This->read_buf_size, text, 0) ? S_FALSE : E_OUTOFMEMORY; } -static HRESULT textstream_writestr(struct textstream *stream, BSTR text) +static HRESULT textstream_write(struct textstream *stream, BSTR text) { DWORD written = 0; BOOL ret; + if (textstream_check_iomode(stream, IOWrite)) + return CTL_E_BADFILEMODE; + if (stream->unicode) { ret = WriteFile(stream->file, text, SysStringByteLen(text), &written, NULL); return (ret && written == SysStringByteLen(text)) ? S_OK : create_error(GetLastError()); @@ -636,14 +639,11 @@ static HRESULT textstream_writestr(struct textstream *stream, BSTR text) static HRESULT WINAPI textstream_Write(ITextStream *iface, BSTR text) { - struct textstream *This = impl_from_ITextStream(iface); - - TRACE("(%p)->(%s)\n", This, debugstr_w(text)); + struct textstream *stream = impl_from_ITextStream(iface); - if (textstream_check_iomode(This, IOWrite)) - return CTL_E_BADFILEMODE; + TRACE("%p, %s.\n", iface, debugstr_w(text)); - return textstream_writestr(This, text); + return textstream_write(stream, text); } static HRESULT textstream_writecrlf(struct textstream *stream) @@ -669,17 +669,14 @@ static HRESULT textstream_writecrlf(struct textstream *stream) static HRESULT WINAPI textstream_WriteLine(ITextStream *iface, BSTR text) { - struct textstream *This = impl_from_ITextStream(iface); + struct textstream *stream = impl_from_ITextStream(iface); HRESULT hr; - TRACE("(%p)->(%s)\n", This, debugstr_w(text)); - - if (textstream_check_iomode(This, IOWrite)) - return CTL_E_BADFILEMODE; + TRACE("%p, %s.\n", iface, debugstr_w(text)); - hr = textstream_writestr(This, text); + hr = textstream_write(stream, text); if (SUCCEEDED(hr)) - hr = textstream_writecrlf(This); + hr = textstream_writecrlf(stream); return hr; }
1
0
0
0
Nikolay Sivov : usp10/tests: Remove workarounds for missing functions.
by Alexandre Julliard
21 Feb '22
21 Feb '22
Module: wine Branch: master Commit: 2a4b57624f26ffe1839f7185753d8901d3074e0f URL:
https://source.winehq.org/git/wine.git/?a=commit;h=2a4b57624f26ffe1839f7185…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sat Feb 19 11:45:22 2022 +0300 usp10/tests: Remove workarounds for missing functions. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/usp10/tests/usp10.c | 122 +++++++++++++++-------------------------------- include/usp10.h | 15 ++++++ 2 files changed, 53 insertions(+), 84 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=2a4b57624f26ffe1839f…
1
0
0
0
← Newer
1
...
42
43
44
45
46
47
48
...
150
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
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
Results per page:
10
25
50
100
200