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
May 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
907 discussions
Start a n
N
ew thread
Bernhard Kölbl : windows.media.speech: Add IAsyncAction iface.
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: 38bf1a70ae6b769b5ca4d8298483b230578dc0f7 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=38bf1a70ae6b769b5ca4d829…
Author: Bernhard Kölbl <besentv(a)gmail.com> Date: Wed Mar 30 12:19:39 2022 +0200 windows.media.speech: Add IAsyncAction iface. Signed-off-by: Bernhard Kölbl <besentv(a)gmail.com> --- dlls/windows.media.speech/async.c | 126 +++++++++++++++++++++++++++++++ dlls/windows.media.speech/private.h | 1 + dlls/windows.media.speech/recognizer.c | 2 +- dlls/windows.media.speech/tests/speech.c | 14 ++-- 4 files changed, 135 insertions(+), 8 deletions(-) diff --git a/dlls/windows.media.speech/async.c b/dlls/windows.media.speech/async.c index eceda4338b3..1abb88528ef 100644 --- a/dlls/windows.media.speech/async.c +++ b/dlls/windows.media.speech/async.c @@ -26,6 +26,132 @@ WINE_DEFAULT_DEBUG_CHANNEL(speech); #define Closed 4 #define HANDLER_NOT_SET ((void *)~(ULONG_PTR)0) +/* + * + * IAsyncAction + * + */ + +struct async_void +{ + IAsyncAction IAsyncAction_iface; + LONG ref; +}; + +static inline struct async_void *impl_from_IAsyncAction( IAsyncAction *iface ) +{ + return CONTAINING_RECORD(iface, struct async_void, IAsyncAction_iface); +} + +HRESULT WINAPI async_void_QueryInterface( IAsyncAction *iface, REFIID iid, void **out ) +{ + struct async_void *impl = impl_from_IAsyncAction(iface); + + TRACE("iface %p, iid %s, out %p.\n", iface, debugstr_guid(iid), out); + + if (IsEqualGUID(iid, &IID_IUnknown) || + IsEqualGUID(iid, &IID_IInspectable) || + IsEqualGUID(iid, &IID_IAgileObject) || + IsEqualGUID(iid, &IID_IAsyncAction)) + { + IInspectable_AddRef((*out = &impl->IAsyncAction_iface)); + return S_OK; + } + + WARN("%s not implemented, returning E_NOINTERFACE.\n", debugstr_guid(iid)); + *out = NULL; + return E_NOINTERFACE; +} + +ULONG WINAPI async_void_AddRef( IAsyncAction *iface ) +{ + struct async_void *impl = impl_from_IAsyncAction(iface); + ULONG ref = InterlockedIncrement(&impl->ref); + TRACE("iface %p, ref %lu.\n", iface, ref); + return ref; +} + +ULONG WINAPI async_void_Release( IAsyncAction *iface ) +{ + struct async_void *impl = impl_from_IAsyncAction(iface); + ULONG ref = InterlockedDecrement(&impl->ref); + TRACE("iface %p, ref %lu.\n", iface, ref); + return ref; +} + +HRESULT WINAPI async_void_GetIids( IAsyncAction *iface, ULONG *iid_count, IID **iids ) +{ + FIXME("iface %p, iid_count %p, iids %p stub!\n", iface, iid_count, iids); + return E_NOTIMPL; +} + +HRESULT WINAPI async_void_GetRuntimeClassName( IAsyncAction *iface, HSTRING *class_name ) +{ + FIXME("iface %p, class_name %p stub!\n", iface, class_name); + return E_NOTIMPL; +} + +HRESULT WINAPI async_void_GetTrustLevel( IAsyncAction *iface, TrustLevel *trust_level ) +{ + FIXME("iface %p, trust_level %p stub!\n", iface, trust_level); + return E_NOTIMPL; +} + +HRESULT WINAPI async_void_put_Completed( IAsyncAction *iface, IAsyncActionCompletedHandler *handler ) +{ + FIXME("iface %p, handler %p stub!\n", iface, handler); + return E_NOTIMPL; +} + +HRESULT WINAPI async_void_get_Completed( IAsyncAction *iface, IAsyncActionCompletedHandler **handler ) +{ + FIXME("iface %p, handler %p stub!\n", iface, handler); + return E_NOTIMPL; +} + +HRESULT WINAPI async_void_GetResults( IAsyncAction *iface ) +{ + FIXME("iface %p stub!\n", iface); + return E_NOTIMPL; +} + +static const struct IAsyncActionVtbl async_void_vtbl = +{ + /* IUnknown methods */ + async_void_QueryInterface, + async_void_AddRef, + async_void_Release, + /* IInspectable methods */ + async_void_GetIids, + async_void_GetRuntimeClassName, + async_void_GetTrustLevel, + /* IAsyncAction methods */ + async_void_put_Completed, + async_void_get_Completed, + async_void_GetResults +}; + + +HRESULT async_action_create( IAsyncAction **out ) +{ + struct async_void *impl; + + TRACE("out %p.\n", out); + + if (!(impl = calloc(1, sizeof(*impl)))) + { + *out = NULL; + return E_OUTOFMEMORY; + } + + impl->IAsyncAction_iface.lpVtbl = &async_void_vtbl; + impl->ref = 1; + + *out = &impl->IAsyncAction_iface; + TRACE("created %p\n", *out); + return S_OK; +} + /* * * IAsyncOperation<IInspectable*> diff --git a/dlls/windows.media.speech/private.h b/dlls/windows.media.speech/private.h index 97afa4d3499..ba8e942fe5f 100644 --- a/dlls/windows.media.speech/private.h +++ b/dlls/windows.media.speech/private.h @@ -71,6 +71,7 @@ struct vector_iids typedef HRESULT (WINAPI *async_operation_inspectable_callback)( IInspectable *invoker, IInspectable **result ); +HRESULT async_action_create( IAsyncAction **out ); HRESULT async_operation_inspectable_create( const GUID *iid, IInspectable *invoker, async_operation_inspectable_callback callback, IAsyncOperation_IInspectable **out ); diff --git a/dlls/windows.media.speech/recognizer.c b/dlls/windows.media.speech/recognizer.c index c78f69b0a67..853e9eb9830 100644 --- a/dlls/windows.media.speech/recognizer.c +++ b/dlls/windows.media.speech/recognizer.c @@ -247,7 +247,7 @@ static HRESULT WINAPI session_set_AutoStopSilenceTimeout( ISpeechContinuousRecog static HRESULT WINAPI session_StartAsync( ISpeechContinuousRecognitionSession *iface, IAsyncAction **action ) { FIXME("iface %p, action %p stub!\n", iface, action); - return E_NOTIMPL; + return async_action_create(action); } static HRESULT WINAPI session_StartWithModeAsync( ISpeechContinuousRecognitionSession *iface, diff --git a/dlls/windows.media.speech/tests/speech.c b/dlls/windows.media.speech/tests/speech.c index 91d8704f2c8..f3b28c40f51 100644 --- a/dlls/windows.media.speech/tests/speech.c +++ b/dlls/windows.media.speech/tests/speech.c @@ -1577,20 +1577,20 @@ static void test_Recognition(void) IAsyncOperation_IInspectable_Release((IAsyncOperation_IInspectable *)operation); hr = ISpeechContinuousRecognitionSession_StartAsync(session, &action); - todo_wine ok(hr == S_OK, "ISpeechContinuousRecognitionSession_StartAsync failed, hr %#lx.\n", hr); - - if (FAILED(hr)) goto skip_action; - - await_async_void(action, &action_handler); - check_async_info((IInspectable *)action, 1, Completed, S_OK); + ok(hr == S_OK, "ISpeechContinuousRecognitionSession_StartAsync failed, hr %#lx.\n", hr); handler = (void *)0xdeadbeef; hr = IAsyncAction_get_Completed(action, &handler); todo_wine ok(hr == S_OK, "IAsyncAction_put_Completed failed, hr %#lx.\n", hr); todo_wine ok(handler == NULL, "Handler was %p.\n", handler); + if (FAILED(hr)) goto skip_action; + + await_async_void(action, &action_handler); + hr = IAsyncAction_QueryInterface(action, &IID_IAsyncInfo, (void **)&info); todo_wine ok(hr == S_OK, "IAsyncAction_QueryInterface failed, hr %#lx.\n", hr); + check_async_info((IInspectable *)action, 1, Completed, S_OK); hr = IAsyncInfo_Cancel(info); todo_wine ok(hr == S_OK, "IAsyncInfo_Cancel failed, hr %#lx.\n", hr); @@ -1660,9 +1660,9 @@ static void test_Recognition(void) todo_wine ok(action != action2, "actions were the same!\n"); IAsyncAction_Release(action2); +skip_action: IAsyncAction_Release(action); -skip_action: hr = ISpeechContinuousRecognitionSession_remove_ResultGenerated(session, token); ok(hr == S_OK, "ISpeechContinuousRecognitionSession_remove_ResultGenerated failed, hr %#lx.\n", hr);
1
0
0
0
Bernhard Kölbl : windows.media.speech/tests: Remove an unnecessary todo_wine_if.
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: e0b47f6e0322ab9a2083b9ad7a4431fb336ddb3b URL:
https://source.winehq.org/git/wine.git/?a=commit;h=e0b47f6e0322ab9a2083b9ad…
Author: Bernhard Kölbl <besentv(a)gmail.com> Date: Fri May 20 14:35:51 2022 +0200 windows.media.speech/tests: Remove an unnecessary todo_wine_if. Signed-off-by: Bernhard Kölbl <besentv(a)gmail.com> --- 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 935afb3c773..91d8704f2c8 100644 --- a/dlls/windows.media.speech/tests/speech.c +++ b/dlls/windows.media.speech/tests/speech.c @@ -452,7 +452,7 @@ static void check_async_info_( unsigned int line, IInspectable *async_obj, UINT3 hr = IAsyncInfo_get_ErrorCode(async_info, &async_hr); if (expect_status < 4) ok_(__FILE__, line)(hr == S_OK, "IAsyncInfo_get_ErrorCode returned %#lx\n", hr); else ok_(__FILE__, line)(hr == E_ILLEGAL_METHOD_CALL, "IAsyncInfo_get_ErrorCode returned %#lx\n", hr); - if (expect_status < 4) todo_wine_if(FAILED(expect_hr)) ok_(__FILE__, line)(async_hr == expect_hr, "got async_hr %#lx\n", async_hr); + if (expect_status < 4) ok_(__FILE__, line)(async_hr == expect_hr, "got async_hr %#lx\n", async_hr); else ok_(__FILE__, line)(async_hr == E_ILLEGAL_METHOD_CALL, "got async_hr %#lx\n", async_hr); IAsyncInfo_Release(async_info);
1
0
0
0
Bernhard Kölbl : windows.media.speech/tests: Fix a few typos.
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: d1b2cceb9949d8acc07fa6ab0096cc6ff1d6678d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d1b2cceb9949d8acc07fa6ab…
Author: Bernhard Kölbl <besentv(a)gmail.com> Date: Fri May 20 13:49:58 2022 +0200 windows.media.speech/tests: Fix a few typos. Signed-off-by: Bernhard Kölbl <besentv(a)gmail.com> --- dlls/windows.media.speech/tests/speech.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dlls/windows.media.speech/tests/speech.c b/dlls/windows.media.speech/tests/speech.c index 6fd683109b4..935afb3c773 100644 --- a/dlls/windows.media.speech/tests/speech.c +++ b/dlls/windows.media.speech/tests/speech.c @@ -390,7 +390,7 @@ HRESULT WINAPI async_inspectable_handler_Invoke( IAsyncOperationCompletedHandler return S_OK; } -static const struct IAsyncOperationCompletedHandler_IInspectableVtbl asnyc_inspectable_handler_vtbl = +static const struct IAsyncOperationCompletedHandler_IInspectableVtbl async_inspectable_handler_vtbl = { /* IUnknown methods */ async_inspectable_handler_QueryInterface, @@ -402,7 +402,7 @@ static const struct IAsyncOperationCompletedHandler_IInspectableVtbl asnyc_inspe static HRESULT WINAPI async_inspectable_handler_create_static( struct async_inspectable_handler *impl, const GUID *iid ) { - impl->IAsyncOperationCompletedHandler_IInspectable_iface.lpVtbl = &asnyc_inspectable_handler_vtbl; + impl->IAsyncOperationCompletedHandler_IInspectable_iface.lpVtbl = &async_inspectable_handler_vtbl; impl->iid = iid; impl->ref = 1; @@ -425,8 +425,8 @@ static void await_async_inspectable_( unsigned int line, IAsyncOperation_IInspec CloseHandle(handler->event_finished); } -#define check_async_info(obj, exp_id, exp_status, exp_hr) check_asnyc_info_(__LINE__, obj, exp_id, exp_status, exp_hr) -static void check_asnyc_info_( unsigned int line, IInspectable *async_obj, UINT32 expect_id, AsyncStatus expect_status, HRESULT expect_hr) +#define check_async_info(obj, exp_id, exp_status, exp_hr) check_async_info_(__LINE__, obj, exp_id, exp_status, exp_hr) +static void check_async_info_( unsigned int line, IInspectable *async_obj, UINT32 expect_id, AsyncStatus expect_status, HRESULT expect_hr) { IAsyncInfo *async_info; AsyncStatus async_status;
1
0
0
0
Nikolay Sivov : vbscript: Implement TimeSerial().
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: b4d42d2cba2454b2d5204ff06bd670084173dd0c URL:
https://source.winehq.org/git/wine.git/?a=commit;h=b4d42d2cba2454b2d5204ff0…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Tue May 24 08:52:07 2022 +0300 vbscript: Implement TimeSerial(). Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/vbscript/global.c | 37 ++++++++++++++++++++++++++++++++++--- dlls/vbscript/tests/api.vbs | 37 +++++++++++++++++++++++++++++++++++++ 2 files changed, 71 insertions(+), 3 deletions(-) diff --git a/dlls/vbscript/global.c b/dlls/vbscript/global.c index 876a41a14b2..90cfd557038 100644 --- a/dlls/vbscript/global.c +++ b/dlls/vbscript/global.c @@ -2144,10 +2144,41 @@ static HRESULT Global_DateSerial(BuiltinDisp *This, VARIANT *args, unsigned args return hres; } -static HRESULT Global_TimeSerial(BuiltinDisp *This, VARIANT *arg, unsigned args_cnt, VARIANT *res) +static HRESULT Global_TimeSerial(BuiltinDisp *This, VARIANT *args, unsigned args_cnt, VARIANT *res) { - FIXME("\n"); - return E_NOTIMPL; + int hour, minute, second; + UDATE ud = {{ 0 }}; + HRESULT hres; + double date; + + TRACE("\n"); + + assert(args_cnt == 3); + + if (V_VT(args) == VT_NULL || V_VT(args + 1) == VT_NULL || V_VT(args + 2) == VT_NULL) + return MAKE_VBSERROR(VBSE_ILLEGAL_NULL_USE); + + hres = to_int(args, &hour); + if (SUCCEEDED(hres)) + hres = to_int(args + 1, &minute); + if (SUCCEEDED(hres)) + hres = to_int(args + 2, &second); + + if (SUCCEEDED(hres)) + { + ud.st.wYear = 1899; + ud.st.wMonth = 12; + ud.st.wDay = 30; + ud.st.wHour = hour; + ud.st.wMinute = minute; + ud.st.wSecond = second; + hres = VarDateFromUdateEx(&ud, 0, 0, &date); + } + + if (SUCCEEDED(hres)) + hres = return_date(res, date); + + return hres; } static HRESULT Global_InputBox(BuiltinDisp *This, VARIANT *arg, unsigned args_cnt, VARIANT *res) diff --git a/dlls/vbscript/tests/api.vbs b/dlls/vbscript/tests/api.vbs index 758013c93ef..be1d4a806c0 100644 --- a/dlls/vbscript/tests/api.vbs +++ b/dlls/vbscript/tests/api.vbs @@ -2165,4 +2165,41 @@ sub testMonthNameError() end sub call testMonthNameError() +sub testTimeSerial(hh, mm, ss, hhexp, mmexp, ssexp, dateexp) + dim x + x = TimeSerial(hh, mm, ss) + call ok(Hour(x) = hhexp, "hour = " & Hour(x) & " expected " & hhexp) + call ok(Minute(x) = mmexp, "minute = " & Minute(x) & " expected " & mmexp) + call ok(Second(x) = ssexp, "second = " & Second(x) & " expected " & ssexp) + call ok(Year(x) = Year(dateexp), "year = " & Year(x)) + call ok(Month(x) = Month(dateexp), "month = " & Month(x)) + call ok(Day(x) = Day(dateexp), "day = " & Day(x)) + call ok(getVT(x) = "VT_DATE*", "getVT = " & getVT(x)) +end sub + +sub testTimeSerialError() + on error resume next + dim x + call Err.clear() + x = TimeSerial(null, 1, 1) + call ok(Err.number = 94, "Err.number = " & Err.number) + call ok(getVT(x) = "VT_EMPTY*", "getVT = " & getVT(x)) + call Err.clear() + call TimeSerial(10, null, 1) + call ok(Err.number = 94, "Err.number = " & Err.number) + call Err.clear() + call TimeSerial(10, 1, null) + call ok(Err.number = 94, "Err.number = " & Err.number) +end sub + +call testTimeSerial(0, 0, 0, 0, 0, 0, DateSerial(1899, 12, 30)) +call testTimeSerial(10, 2, 1, 10, 2, 1, DateSerial(1899, 12, 30)) +call testTimeSerial(0, 2, 1, 0, 2, 1, DateSerial(1899, 12, 30)) +call testTimeSerial(24, 2, 1, 0, 2, 1, DateSerial(1899, 12, 31)) +call testTimeSerial(25, 2, 1, 1, 2, 1, DateSerial(1899, 12, 31)) +call testTimeSerial(50, 2, 1, 2, 2, 1, DateSerial(1900, 1, 1)) +call testTimeSerial(10, 60, 2, 11, 0, 2, DateSerial(1899, 12, 30)) +call testTimeSerial(10, 0, 60, 10, 1, 0, DateSerial(1899, 12, 30)) +call testTimeSerialError() + Call reportSuccess()
1
0
0
0
Nikolay Sivov : vbscript: Handle null arguments in MonthName().
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: ea9281d33a9a2832f859a834ea7bc6a93204b214 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ea9281d33a9a2832f859a834…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Tue May 24 08:52:06 2022 +0300 vbscript: Handle null arguments in MonthName(). Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/vbscript/global.c | 3 +++ dlls/vbscript/tests/api.vbs | 17 +++++++++++++++++ 2 files changed, 20 insertions(+) diff --git a/dlls/vbscript/global.c b/dlls/vbscript/global.c index 80348a5288f..876a41a14b2 100644 --- a/dlls/vbscript/global.c +++ b/dlls/vbscript/global.c @@ -2897,6 +2897,9 @@ static HRESULT Global_MonthName(BuiltinDisp *This, VARIANT *args, unsigned args_ assert(args_cnt == 1 || args_cnt == 2); + if(V_VT(args) == VT_NULL || (args_cnt == 2 && V_VT(args+1) == VT_NULL)) + return MAKE_VBSERROR(VBSE_ILLEGAL_NULL_USE); + hres = to_int(args, &month); if(FAILED(hres)) return hres; diff --git a/dlls/vbscript/tests/api.vbs b/dlls/vbscript/tests/api.vbs index 617589053c6..758013c93ef 100644 --- a/dlls/vbscript/tests/api.vbs +++ b/dlls/vbscript/tests/api.vbs @@ -2148,4 +2148,21 @@ call testWeekday(DateSerial(2000, 1, 1), vbFriday, 2) call testWeekday(DateSerial(2000, 1, 1), vbSaturday, 1) call testWeekdayError() +sub testMonthNameError() + on error resume next + call Err.clear() + call MonthName(null) + call ok(Err.number = 94, "Err.number = " & Err.number) + call Err.clear() + call MonthName(1, null) + call ok(Err.number = 94, "Err.number = " & Err.number) + call Err.clear() + call MonthName(null, null) + call ok(Err.number = 94, "Err.number = " & Err.number) + call Err.clear() + call MonthName("a", null) + call ok(Err.number = 94, "Err.number = " & Err.number) +end sub +call testMonthNameError() + Call reportSuccess()
1
0
0
0
Zebediah Figura : d3d10core/tests: Add a test for 2D partial RTV slices of a 3D texture.
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: f371ae8f26b359ed6f27c766a663a6573b7657c6 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=f371ae8f26b359ed6f27c766…
Author: Zebediah Figura <zfigura(a)codeweavers.com> Date: Mon May 23 17:37:45 2022 -0500 d3d10core/tests: Add a test for 2D partial RTV slices of a 3D texture. This succeeds with the Vulkan renderer. Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3d10core/tests/d3d10core.c | 113 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 113 insertions(+) diff --git a/dlls/d3d10core/tests/d3d10core.c b/dlls/d3d10core/tests/d3d10core.c index 49622bd0e26..15f306f9559 100644 --- a/dlls/d3d10core/tests/d3d10core.c +++ b/dlls/d3d10core/tests/d3d10core.c @@ -19217,6 +19217,118 @@ static void test_dynamic_map_synchronization(void) release_test_context(&test_context); } +static void test_rtv_depth_slice(void) +{ + D3D10_RENDER_TARGET_VIEW_DESC rtv_desc; + struct d3d10core_test_context test_context; + ID3D10ShaderResourceView *srv; + struct resource_readback rb; + ID3D10Texture3D *texture; + unsigned int i, colour; + ID3D10PixelShader *ps; + ID3D10Device *device; + HRESULT hr; + + static const DWORD ps_code[] = + { +#if 0 + Texture3D t; + + float4 main(float4 pos : SV_Position) : SV_Target + { + return t[int3(pos.x / 640, pos.y / 480, pos.y * 4 / 480)]; + } +#endif + 0x43425844, 0xef9f40c6, 0xbc613d8c, 0x02b23c2b, 0xd2cfcfe7, 0x00000001, 0x00000148, 0x00000003, + 0x0000002c, 0x00000060, 0x00000094, 0x4e475349, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, + 0x00000000, 0x00000001, 0x00000003, 0x00000000, 0x0000030f, 0x505f5653, 0x7469736f, 0x006e6f69, + 0x4e47534f, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000000, 0x00000003, + 0x00000000, 0x0000000f, 0x545f5653, 0x65677261, 0xabab0074, 0x52444853, 0x000000ac, 0x00000040, + 0x0000002b, 0x04002858, 0x00107000, 0x00000000, 0x00005555, 0x04002064, 0x00101032, 0x00000000, + 0x00000001, 0x03000065, 0x001020f2, 0x00000000, 0x02000068, 0x00000001, 0x0a000038, 0x00100072, + 0x00000000, 0x00101146, 0x00000000, 0x00004002, 0x3acccccd, 0x3b088889, 0x3c088889, 0x00000000, + 0x0500001b, 0x00100072, 0x00000000, 0x00100246, 0x00000000, 0x05000036, 0x00100082, 0x00000000, + 0x00004001, 0x00000000, 0x0700002d, 0x001020f2, 0x00000000, 0x00100e46, 0x00000000, 0x00107e46, + 0x00000000, 0x0100003e, + }; + + static const struct + { + struct vec4 ps_colour; + unsigned int output; + } + colours[] = + { + {{1.0f, 0.0f, 0.0f, 1.0f}, 0xff0000ff}, + {{0.0f, 1.0f, 0.0f, 1.0f}, 0xff00ff00}, + {{0.0f, 0.0f, 1.0f, 1.0f}, 0xffff0000}, + {{1.0f, 1.0f, 1.0f, 1.0f}, 0xffffffff}, + }; + + static const D3D10_TEXTURE3D_DESC texture_desc = + { + .Width = 32, + .Height = 32, + .Depth = ARRAY_SIZE(colours), + .MipLevels = 1, + .Format = DXGI_FORMAT_R32G32B32A32_FLOAT, + .Usage = D3D10_USAGE_DEFAULT, + .BindFlags = D3D10_BIND_SHADER_RESOURCE | D3D10_BIND_RENDER_TARGET, + }; + + if (!init_test_context(&test_context)) + return; + device = test_context.device; + + hr = ID3D10Device_CreatePixelShader(device, ps_code, sizeof(ps_code), &ps); + ok(hr == S_OK, "Failed to create pixel shader, hr %#x.\n", hr); + + hr = ID3D10Device_CreateTexture3D(device, &texture_desc, NULL, &texture); + ok(hr == S_OK, "Got hr %#x.\n", hr); + + hr = ID3D10Device_CreateShaderResourceView(device, (ID3D10Resource *)texture, NULL, &srv); + ok(hr == S_OK, "Got hr %#x.\n", hr); + + for (i = 0; i < texture_desc.Depth; ++i) + { + ID3D10RenderTargetView *rtv; + + rtv_desc.ViewDimension = D3D10_RTV_DIMENSION_TEXTURE3D; + rtv_desc.Format = texture_desc.Format; + rtv_desc.Texture3D.MipSlice = 0; + rtv_desc.Texture3D.FirstWSlice = i; + rtv_desc.Texture3D.WSize = 1; + hr = ID3D10Device_CreateRenderTargetView(device, (ID3D10Resource *)texture, &rtv_desc, &rtv); + ok(hr == S_OK, "Got hr %#x.\n", hr); + + ID3D10Device_OMSetRenderTargets(device, 1, &rtv, NULL); + draw_color_quad(&test_context, &colours[i].ps_colour); + + ID3D10RenderTargetView_Release(rtv); + } + + ID3D10Device_OMSetRenderTargets(device, 1, &test_context.backbuffer_rtv, NULL); + ID3D10Device_PSSetShaderResources(device, 0, 1, &srv); + ID3D10Device_PSSetShader(device, ps); + draw_quad(&test_context); + + get_texture_readback(test_context.backbuffer, 0, &rb); + for (i = 0; i < texture_desc.Depth; ++i) + { + unsigned int x = 320, y = 60 + i * 480 / 4; + + colour = get_readback_color(&rb, x, y); + todo_wine ok(colour == colours[i].output, "Got unexpected colour 0x%08x at (%u, %u), expected 0x%08x.\n", + colour, x, y, colours[i].output); + } + release_resource_readback(&rb); + + ID3D10ShaderResourceView_Release(srv); + ID3D10Texture3D_Release(texture); + ID3D10PixelShader_Release(ps); + release_test_context(&test_context); +} + START_TEST(d3d10core) { unsigned int argc, i; @@ -19347,6 +19459,7 @@ START_TEST(d3d10core) queue_test(test_unbound_streams); queue_test(test_texture_compressed_3d); queue_test(test_dynamic_map_synchronization); + queue_test(test_rtv_depth_slice); run_queued_tests();
1
0
0
0
Zebediah Figura : d3d11/tests: Add a test for 2D partial RTV slices of a 3D texture.
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: ab88f9b51834ec76145b5578b5fffb5fb9037f80 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ab88f9b51834ec76145b5578…
Author: Zebediah Figura <zfigura(a)codeweavers.com> Date: Mon May 23 17:37:44 2022 -0500 d3d11/tests: Add a test for 2D partial RTV slices of a 3D texture. This succeeds with the Vulkan renderer. Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3d11/tests/d3d11.c | 115 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 115 insertions(+) diff --git a/dlls/d3d11/tests/d3d11.c b/dlls/d3d11/tests/d3d11.c index 99f304e5b68..8225237568f 100644 --- a/dlls/d3d11/tests/d3d11.c +++ b/dlls/d3d11/tests/d3d11.c @@ -34199,6 +34199,120 @@ static void test_logic_op(void) release_test_context(&test_context); } +static void test_rtv_depth_slice(void) +{ + D3D11_RENDER_TARGET_VIEW_DESC rtv_desc; + struct d3d11_test_context test_context; + ID3D11ShaderResourceView *srv; + ID3D11DeviceContext *context; + struct resource_readback rb; + ID3D11Texture3D *texture; + unsigned int i, colour; + ID3D11PixelShader *ps; + ID3D11Device *device; + HRESULT hr; + + static const DWORD ps_code[] = + { +#if 0 + Texture3D t; + + float4 main(float4 pos : SV_Position) : SV_Target + { + return t[int3(pos.x / 640, pos.y / 480, pos.y * 4 / 480)]; + } +#endif + 0x43425844, 0xef9f40c6, 0xbc613d8c, 0x02b23c2b, 0xd2cfcfe7, 0x00000001, 0x00000148, 0x00000003, + 0x0000002c, 0x00000060, 0x00000094, 0x4e475349, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, + 0x00000000, 0x00000001, 0x00000003, 0x00000000, 0x0000030f, 0x505f5653, 0x7469736f, 0x006e6f69, + 0x4e47534f, 0x0000002c, 0x00000001, 0x00000008, 0x00000020, 0x00000000, 0x00000000, 0x00000003, + 0x00000000, 0x0000000f, 0x545f5653, 0x65677261, 0xabab0074, 0x52444853, 0x000000ac, 0x00000040, + 0x0000002b, 0x04002858, 0x00107000, 0x00000000, 0x00005555, 0x04002064, 0x00101032, 0x00000000, + 0x00000001, 0x03000065, 0x001020f2, 0x00000000, 0x02000068, 0x00000001, 0x0a000038, 0x00100072, + 0x00000000, 0x00101146, 0x00000000, 0x00004002, 0x3acccccd, 0x3b088889, 0x3c088889, 0x00000000, + 0x0500001b, 0x00100072, 0x00000000, 0x00100246, 0x00000000, 0x05000036, 0x00100082, 0x00000000, + 0x00004001, 0x00000000, 0x0700002d, 0x001020f2, 0x00000000, 0x00100e46, 0x00000000, 0x00107e46, + 0x00000000, 0x0100003e, + }; + + static const struct + { + struct vec4 ps_colour; + unsigned int output; + } + colours[] = + { + {{1.0f, 0.0f, 0.0f, 1.0f}, 0xff0000ff}, + {{0.0f, 1.0f, 0.0f, 1.0f}, 0xff00ff00}, + {{0.0f, 0.0f, 1.0f, 1.0f}, 0xffff0000}, + {{1.0f, 1.0f, 1.0f, 1.0f}, 0xffffffff}, + }; + + static const D3D11_TEXTURE3D_DESC texture_desc = + { + .Width = 32, + .Height = 32, + .Depth = ARRAY_SIZE(colours), + .MipLevels = 1, + .Format = DXGI_FORMAT_R32G32B32A32_FLOAT, + .Usage = D3D11_USAGE_DEFAULT, + .BindFlags = D3D11_BIND_SHADER_RESOURCE | D3D11_BIND_RENDER_TARGET, + }; + + if (!init_test_context(&test_context, NULL)) + return; + device = test_context.device; + context = test_context.immediate_context; + + hr = ID3D11Device_CreatePixelShader(device, ps_code, sizeof(ps_code), NULL, &ps); + ok(hr == S_OK, "Failed to create pixel shader, hr %#lx.\n", hr); + + hr = ID3D11Device_CreateTexture3D(device, &texture_desc, NULL, &texture); + ok(hr == S_OK, "Got hr %#lx.\n", hr); + + hr = ID3D11Device_CreateShaderResourceView(device, (ID3D11Resource *)texture, NULL, &srv); + ok(hr == S_OK, "Got hr %#lx.\n", hr); + + for (i = 0; i < texture_desc.Depth; ++i) + { + ID3D11RenderTargetView *rtv; + + rtv_desc.ViewDimension = D3D11_RTV_DIMENSION_TEXTURE3D; + rtv_desc.Format = texture_desc.Format; + rtv_desc.Texture3D.MipSlice = 0; + rtv_desc.Texture3D.FirstWSlice = i; + rtv_desc.Texture3D.WSize = 1; + hr = ID3D11Device_CreateRenderTargetView(device, (ID3D11Resource *)texture, &rtv_desc, &rtv); + ok(hr == S_OK, "Got hr %#lx.\n", hr); + + ID3D11DeviceContext_OMSetRenderTargets(context, 1, &rtv, NULL); + draw_color_quad(&test_context, &colours[i].ps_colour); + + ID3D11RenderTargetView_Release(rtv); + } + + ID3D11DeviceContext_OMSetRenderTargets(context, 1, &test_context.backbuffer_rtv, NULL); + ID3D11DeviceContext_PSSetShaderResources(context, 0, 1, &srv); + ID3D11DeviceContext_PSSetShader(context, ps, NULL, 0); + draw_quad(&test_context); + + get_texture_readback(test_context.backbuffer, 0, &rb); + for (i = 0; i < texture_desc.Depth; ++i) + { + unsigned int x = 320, y = 60 + i * 480 / 4; + + colour = get_readback_color(&rb, x, y, 0); + todo_wine ok(colour == colours[i].output, "Got unexpected colour 0x%08x at (%u, %u), expected 0x%08x.\n", + colour, x, y, colours[i].output); + } + release_resource_readback(&rb); + + ID3D11ShaderResourceView_Release(srv); + ID3D11Texture3D_Release(texture); + ID3D11PixelShader_Release(ps); + release_test_context(&test_context); +} + START_TEST(d3d11) { unsigned int argc, i; @@ -34380,6 +34494,7 @@ START_TEST(d3d11) queue_test(test_dynamic_map_synchronization); queue_test(test_user_defined_annotation); queue_test(test_logic_op); + queue_test(test_rtv_depth_slice); run_queued_tests();
1
0
0
0
Zebediah Figura : wined3d: Correctly handle 3D textures in wined3d_view_{load, invalidate}_location().
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: 7c529506af6c8ad1b8a2d869eb78930469ded85f URL:
https://source.winehq.org/git/wine.git/?a=commit;h=7c529506af6c8ad1b8a2d869…
Author: Zebediah Figura <zfigura(a)codeweavers.com> Date: Mon May 23 17:37:43 2022 -0500 wined3d: Correctly handle 3D textures in wined3d_view_{load, invalidate}_location(). The sub-resource index should not be offset by the layer index, which represents a depth offset. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=53027
Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/wined3d/view.c | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/dlls/wined3d/view.c b/dlls/wined3d/view.c index f2dea8f0f9a..dbd385219f0 100644 --- a/dlls/wined3d/view.c +++ b/dlls/wined3d/view.c @@ -315,7 +315,7 @@ static void create_buffer_view(struct wined3d_gl_view *view, struct wined3d_cont static void wined3d_view_invalidate_location(struct wined3d_resource *resource, const struct wined3d_view_desc *desc, DWORD location) { - unsigned int i, sub_resource_idx, layer_count; + unsigned int i, sub_resource_idx; struct wined3d_texture *texture; if (resource->type == WINED3D_RTYPE_BUFFER) @@ -325,17 +325,21 @@ static void wined3d_view_invalidate_location(struct wined3d_resource *resource, } texture = texture_from_resource(resource); + if (resource->type == WINED3D_RTYPE_TEXTURE_3D) + { + wined3d_texture_invalidate_location(texture, desc->u.texture.level_idx, location); + return; + } sub_resource_idx = desc->u.texture.layer_idx * texture->level_count + desc->u.texture.level_idx; - layer_count = resource->type != WINED3D_RTYPE_TEXTURE_3D ? desc->u.texture.layer_count : 1; - for (i = 0; i < layer_count; ++i, sub_resource_idx += texture->level_count) + for (i = 0; i < desc->u.texture.layer_count; ++i, sub_resource_idx += texture->level_count) wined3d_texture_invalidate_location(texture, sub_resource_idx, location); } static void wined3d_view_load_location(struct wined3d_resource *resource, const struct wined3d_view_desc *desc, struct wined3d_context *context, DWORD location) { - unsigned int i, sub_resource_idx, layer_count; + unsigned int i, sub_resource_idx; struct wined3d_texture *texture; if (resource->type == WINED3D_RTYPE_BUFFER) @@ -345,9 +349,14 @@ static void wined3d_view_load_location(struct wined3d_resource *resource, } texture = texture_from_resource(resource); + if (resource->type == WINED3D_RTYPE_TEXTURE_3D) + { + wined3d_texture_load_location(texture, desc->u.texture.level_idx, context, location); + return; + } + sub_resource_idx = desc->u.texture.layer_idx * texture->level_count + desc->u.texture.level_idx; - layer_count = resource->type != WINED3D_RTYPE_TEXTURE_3D ? desc->u.texture.layer_count : 1; - for (i = 0; i < layer_count; ++i, sub_resource_idx += texture->level_count) + for (i = 0; i < desc->u.texture.layer_count; ++i, sub_resource_idx += texture->level_count) wined3d_texture_load_location(texture, sub_resource_idx, context, location); }
1
0
0
0
Hans Leidekker : crypt32/tests: Add more OCSP revocation tests.
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: 74832c2177808c6222d44f7e4580de84e0ada8f0 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=74832c2177808c6222d44f7e…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Tue May 24 09:46:22 2022 +0200 crypt32/tests: Add more OCSP revocation tests. Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/crypt32/tests/cert.c | 552 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 552 insertions(+) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=74832c2177808c6222d4…
1
0
0
0
Hans Leidekker : cryptnet: Give precedence to OID_AUTHORITY_INFO_ACCESS in verify_cert_revocation().
by Alexandre Julliard
24 May '22
24 May '22
Module: wine Branch: master Commit: f74271648776969cc8d4b914ac8d409c4f37f6d5 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=f74271648776969cc8d4b914…
Author: Hans Leidekker <hans(a)codeweavers.com> Date: Tue May 24 09:46:21 2022 +0200 cryptnet: Give precedence to OID_AUTHORITY_INFO_ACCESS in verify_cert_revocation(). Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/cryptnet/cryptnet_main.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/dlls/cryptnet/cryptnet_main.c b/dlls/cryptnet/cryptnet_main.c index 6654ef77c8c..e8c17407a9b 100644 --- a/dlls/cryptnet/cryptnet_main.c +++ b/dlls/cryptnet/cryptnet_main.c @@ -2139,17 +2139,13 @@ static DWORD verify_cert_revocation(const CERT_CONTEXT *cert, FILETIME *pTime, if (find_cached_revocation_status(&cert->pCertInfo->SerialNumber, pTime, pRevStatus)) return pRevStatus->dwError; - if ((ext = CertFindExtension(szOID_CRL_DIST_POINTS, - cert->pCertInfo->cExtension, cert->pCertInfo->rgExtension))) + if ((ext = CertFindExtension(szOID_AUTHORITY_INFO_ACCESS, cert->pCertInfo->cExtension, cert->pCertInfo->rgExtension))) { - error = verify_cert_revocation_from_dist_points_ext(&ext->Value, cert, - pTime, dwFlags, pRevPara, pRevStatus); + error = verify_cert_revocation_from_aia_ext(&ext->Value, cert, pTime, dwFlags, pRevPara, pRevStatus); } - else if ((ext = CertFindExtension(szOID_AUTHORITY_INFO_ACCESS, - cert->pCertInfo->cExtension, cert->pCertInfo->rgExtension))) + else if ((ext = CertFindExtension(szOID_CRL_DIST_POINTS, cert->pCertInfo->cExtension, cert->pCertInfo->rgExtension))) { - error = verify_cert_revocation_from_aia_ext(&ext->Value, cert, pTime, - dwFlags, pRevPara, pRevStatus); + error = verify_cert_revocation_from_dist_points_ext(&ext->Value, cert, pTime, dwFlags, pRevPara, pRevStatus); } else {
1
0
0
0
← Newer
1
...
21
22
23
24
25
26
27
...
91
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
Results per page:
10
25
50
100
200