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
June 2009
----- 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
5 participants
1115 discussions
Start a n
N
ew thread
Paul Vriens : user32/tests: Remove a trace() message.
by Alexandre Julliard
04 Jun '09
04 Jun '09
Module: wine Branch: master Commit: 96ef5d38affd2daacb1170fcdd54354fd4a10ae9 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=96ef5d38affd2daacb1170fcd…
Author: Paul Vriens <Paul.Vriens.Wine(a)gmail.com> Date: Thu Jun 4 09:32:43 2009 +0200 user32/tests: Remove a trace() message. --- dlls/user32/tests/msg.c | 1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/dlls/user32/tests/msg.c b/dlls/user32/tests/msg.c index 72cf9ed..dfc4c0d 100644 --- a/dlls/user32/tests/msg.c +++ b/dlls/user32/tests/msg.c @@ -3972,7 +3972,6 @@ static void test_hv_scroll_1(HWND hwnd, INT ctl, DWORD clear, DWORD set, INT min xmin = 0xdeadbeef; xmax = 0xdeadbeef; - trace("Ignore GetScrollRange error below if you are on Win9x\n"); ret = GetScrollRange(hwnd, ctl, &xmin, &xmax); ok( ret, "GetScrollRange(%d) error %d\n", ctl, GetLastError()); ok_sequence(WmEmptySeq, "GetScrollRange(SB_HORZ/SB_VERT) empty sequence", FALSE);
1
0
0
0
Paul Vriens : kernel32/tests: Skip WritePrivateProfileString tests on Win9x /WinME.
by Alexandre Julliard
04 Jun '09
04 Jun '09
Module: wine Branch: master Commit: eca3d7487715d92dc43c841d8bb8a6f9522bc4cc URL:
http://source.winehq.org/git/wine.git/?a=commit;h=eca3d7487715d92dc43c841d8…
Author: Paul Vriens <Paul.Vriens.Wine(a)gmail.com> Date: Wed Jun 3 21:56:10 2009 +0200 kernel32/tests: Skip WritePrivateProfileString tests on Win9x/WinME. --- dlls/kernel32/tests/profile.c | 21 +++++++++++++-------- 1 files changed, 13 insertions(+), 8 deletions(-) diff --git a/dlls/kernel32/tests/profile.c b/dlls/kernel32/tests/profile.c index fbf5d24..b9a71d3 100644 --- a/dlls/kernel32/tests/profile.c +++ b/dlls/kernel32/tests/profile.c @@ -822,18 +822,12 @@ static void test_GetPrivateProfileString(const char *content, const char *descri DeleteFileA(filename); } -static DWORD timeout = 0; - static BOOL check_binary_file_data(LPCSTR path, const VOID *data, DWORD size) { HANDLE file; CHAR buf[MAX_PATH]; BOOL ret; - /* Sleep() is needed on Win9x and WinME */ - if (timeout) - Sleep(timeout); - file = CreateFileA(path, GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, 0, 0); if (file == INVALID_HANDLE_VALUE) return FALSE; @@ -864,6 +858,19 @@ static void test_WritePrivateProfileString(void) CHAR path[MAX_PATH]; CHAR temp[MAX_PATH]; + SetLastError(0xdeadbeef); + ret = WritePrivateProfileStringW(NULL, NULL, NULL, NULL); + if (!ret && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED) + { + /* Win9x/WinME needs (variable) timeouts between tests and even long timeouts don't + * guarantee a correct result. + * Win9x/WinMe also produces different ini files where there is always a newline before + * a section start (except for the first one). + */ + win_skip("WritePrivateProfileString on Win9x/WinME is hard to test reliably\n"); + return; + } + GetTempPathA(MAX_PATH, temp); GetTempFileNameA(temp, "wine", 0, path); DeleteFileA(path); @@ -878,8 +885,6 @@ static void test_WritePrivateProfileString(void) broken(GetLastError() == ERROR_INVALID_PARAMETER) || /* NT4 */ broken(GetLastError() == 0xdeadbeef), /* Win9x and WinME */ "Expected ERROR_FILE_NOT_FOUND, got %d\n", GetLastError()); - if (GetLastError() == 0xdeadbeef) - timeout = 1000; ok(GetFileAttributesA(path) == INVALID_FILE_ATTRIBUTES, "Expected path to not exist\n");
1
0
0
0
Paul Vriens : ole32/tests: Fix remaining test failures on NT4 and below.
by Alexandre Julliard
04 Jun '09
04 Jun '09
Module: wine Branch: master Commit: cb81487707ce146823d5a5df1534e156329085be URL:
http://source.winehq.org/git/wine.git/?a=commit;h=cb81487707ce146823d5a5df1…
Author: Paul Vriens <Paul.Vriens.Wine(a)gmail.com> Date: Wed Jun 3 17:15:30 2009 +0200 ole32/tests: Fix remaining test failures on NT4 and below. --- dlls/ole32/tests/storage32.c | 14 ++++++++++---- 1 files changed, 10 insertions(+), 4 deletions(-) diff --git a/dlls/ole32/tests/storage32.c b/dlls/ole32/tests/storage32.c index e561861..29ff0c6 100644 --- a/dlls/ole32/tests/storage32.c +++ b/dlls/ole32/tests/storage32.c @@ -1336,8 +1336,11 @@ static void test_simple(void) ok(upos.QuadPart == 3, "got %d\n", upos.u.LowPart); r = IStream_Stat(stm, &stat, STATFLAG_NONAME); - ok(r == S_OK, "got %08x\n", r); - ok(stat.cbSize.QuadPart == 3, "got %d\n", stat.cbSize.u.LowPart); + ok(r == S_OK || + broken(r == STG_E_INVALIDFUNCTION), /* NT4 and below */ + "got %08x\n", r); + if (r == S_OK) + ok(stat.cbSize.QuadPart == 3, "got %d\n", stat.cbSize.u.LowPart); pos.QuadPart = 1; r = IStream_Seek(stm, pos, STREAM_SEEK_SET, &upos); @@ -1345,8 +1348,11 @@ static void test_simple(void) ok(upos.QuadPart == 1, "got %d\n", upos.u.LowPart); r = IStream_Stat(stm, &stat, STATFLAG_NONAME); - ok(r == S_OK, "got %08x\n", r); - ok(stat.cbSize.QuadPart == 1, "got %d\n", stat.cbSize.u.LowPart); + ok(r == S_OK || + broken(r == STG_E_INVALIDFUNCTION), /* NT4 and below */ + "got %08x\n", r); + if (r == S_OK) + ok(stat.cbSize.QuadPart == 1, "got %d\n", stat.cbSize.u.LowPart); IStream_Release(stm);
1
0
0
0
Vincent Povirk : winex11.drv: Don' t use XEvents uninitialized when waits time out.
by Alexandre Julliard
04 Jun '09
04 Jun '09
Module: wine Branch: master Commit: cedc8e709914b3fb9584fd5194c5e40983efa9db URL:
http://source.winehq.org/git/wine.git/?a=commit;h=cedc8e709914b3fb9584fd519…
Author: Vincent Povirk <vincent(a)codeweavers.com> Date: Wed Jun 3 08:54:22 2009 -0500 winex11.drv: Don't use XEvents uninitialized when waits time out. --- dlls/winex11.drv/clipboard.c | 11 ++++++++++- 1 files changed, 10 insertions(+), 1 deletions(-) diff --git a/dlls/winex11.drv/clipboard.c b/dlls/winex11.drv/clipboard.c index f14a84c..b634451 100644 --- a/dlls/winex11.drv/clipboard.c +++ b/dlls/winex11.drv/clipboard.c @@ -1842,6 +1842,11 @@ static BOOL X11DRV_CLIPBOARD_QueryTargets(Display *display, Window w, Atom selec usleep(SELECTION_WAIT); } + if (i == SELECTION_RETRIES) + { + ERR("Timed out waiting for SelectionNotify event\n"); + return FALSE; + } /* Verify that the selection returned a valid TARGETS property */ if ((xe->xselection.target != target) || (xe->xselection.property == None)) { @@ -2111,8 +2116,12 @@ static BOOL X11DRV_CLIPBOARD_ReadSelectionData(Display *display, LPWINE_CLIPDATA usleep(SELECTION_WAIT); } + if (i == SELECTION_RETRIES) + { + ERR("Timed out waiting for SelectionNotify event\n"); + } /* Verify that the selection returned a valid TARGETS property */ - if (xe.xselection.property != None) + else if (xe.xselection.property != None) { /* * Read the contents of the X selection property
1
0
0
0
Alexandre Julliard : rpcrt4: Add checks for the number of methods being larger than what we support.
by Alexandre Julliard
04 Jun '09
04 Jun '09
Module: wine Branch: master Commit: cbf9d1b0c6bca854c23044c0467a5841e75178e5 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=cbf9d1b0c6bca854c23044c04…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Jun 3 16:52:06 2009 +0200 rpcrt4: Add checks for the number of methods being larger than what we support. --- dlls/rpcrt4/cproxy.c | 5 +++++ dlls/rpcrt4/cstub.c | 10 ++++++++++ 2 files changed, 15 insertions(+), 0 deletions(-) diff --git a/dlls/rpcrt4/cproxy.c b/dlls/rpcrt4/cproxy.c index 6461612..5186ea6 100644 --- a/dlls/rpcrt4/cproxy.c +++ b/dlls/rpcrt4/cproxy.c @@ -133,6 +133,11 @@ static BOOL fill_stubless_table( IUnknownVtbl *vtbl, DWORD num ) const void **entry = (const void **)(vtbl + 1); DWORD i, j; + if (num - 3 > BLOCK_SIZE * MAX_BLOCKS) + { + FIXME( "%u methods not supported\n", num ); + return FALSE; + } for (i = 0; i < (num - 3 + BLOCK_SIZE - 1) / BLOCK_SIZE; i++) { const struct thunk *block = method_blocks[i]; diff --git a/dlls/rpcrt4/cstub.c b/dlls/rpcrt4/cstub.c index 3e1ae8f..95ac1d8 100644 --- a/dlls/rpcrt4/cstub.c +++ b/dlls/rpcrt4/cstub.c @@ -201,6 +201,11 @@ static BOOL fill_delegated_stub_table(IUnknownVtbl *vtbl, DWORD num) const void **entry = (const void **)(vtbl + 1); DWORD i, j; + if (num - 3 > BLOCK_SIZE * MAX_BLOCKS) + { + FIXME( "%u methods not supported\n", num ); + return FALSE; + } vtbl->QueryInterface = delegating_QueryInterface; vtbl->AddRef = delegating_AddRef; vtbl->Release = delegating_Release; @@ -218,6 +223,11 @@ BOOL fill_delegated_proxy_table(IUnknownVtbl *vtbl, DWORD num) const void **entry = (const void **)(vtbl + 1); DWORD i, j; + if (num - 3 > BLOCK_SIZE * MAX_BLOCKS) + { + FIXME( "%u methods not supported\n", num ); + return FALSE; + } vtbl->QueryInterface = IUnknown_QueryInterface_Proxy; vtbl->AddRef = IUnknown_AddRef_Proxy; vtbl->Release = IUnknown_Release_Proxy;
1
0
0
0
Alexandre Julliard : rpcrt4/tests: Add tests for the contents of virtual table for delegated proxies.
by Alexandre Julliard
04 Jun '09
04 Jun '09
Module: wine Branch: master Commit: 066060a520958fc64bf903cc7109f4f25519ebaa URL:
http://source.winehq.org/git/wine.git/?a=commit;h=066060a520958fc64bf903cc7…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Jun 3 16:48:48 2009 +0200 rpcrt4/tests: Add tests for the contents of virtual table for delegated proxies. --- dlls/rpcrt4/tests/cstub.c | 76 ++++++++++++++++++++++++++++++++++++++------ 1 files changed, 65 insertions(+), 11 deletions(-) diff --git a/dlls/rpcrt4/tests/cstub.c b/dlls/rpcrt4/tests/cstub.c index 4ef70c2..e3edee7 100644 --- a/dlls/rpcrt4/tests/cstub.c +++ b/dlls/rpcrt4/tests/cstub.c @@ -259,13 +259,14 @@ static CInterfaceStubVtbl if2_stub_vtbl = { CStdStubBuffer_DELEGATING_METHODS } }; -static CINTERFACE_PROXY_VTABLE(4) if3_proxy_vtbl = +static CINTERFACE_PROXY_VTABLE(5) if3_proxy_vtbl = { { &IID_if3 }, { IUnknown_QueryInterface_Proxy, IUnknown_AddRef_Proxy, IUnknown_Release_Proxy , - if1_fn1_Proxy + if1_fn1_Proxy, + 0 } }; @@ -298,7 +299,7 @@ static CInterfaceStubVtbl if3_stub_vtbl = { &IID_if3, &if3_server_info, - 4, + 5, &if1_table[-3] }, { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } @@ -430,9 +431,14 @@ static const ProxyFileInfo *proxy_file_list[] = { static IPSFactoryBuffer *test_NdrDllGetClassObject(void) { + HMODULE rpcrt4 = GetModuleHandleA("rpcrt4.dll"); IPSFactoryBuffer *ppsf = NULL; + const PCInterfaceProxyVtblList* proxy_vtbl; + const PCInterfaceStubVtblList* stub_vtbl; const CLSID PSDispatch = {0x20420, 0, 0, {0xc0, 0, 0, 0, 0, 0, 0, 0x46}}; const CLSID CLSID_Unknown = {0x45678, 0x1234, 0x6666, {0xff, 0x67, 0x45, 0x98, 0x76, 0x12, 0x34, 0x56}}; + static const GUID * const interfaces[] = { &IID_if1, &IID_if2, &IID_if3, &IID_if4 }; + UINT i; HRESULT r; HMODULE hmod = GetModuleHandleA("rpcrt4.dll"); void *CStd_QueryInterface = GetProcAddress(hmod, "CStdStubBuffer_QueryInterface"); @@ -457,22 +463,26 @@ static IPSFactoryBuffer *test_NdrDllGetClassObject(void) ok(r == S_OK, "ret %08x\n", r); ok(ppsf != NULL, "ppsf == NULL\n"); + proxy_vtbl = PSFactoryBuffer.pProxyFileList[0]->pProxyVtblList; + stub_vtbl = PSFactoryBuffer.pProxyFileList[0]->pStubVtblList; ok(PSFactoryBuffer.pProxyFileList == proxy_file_list, "pfl not the same\n"); - ok(PSFactoryBuffer.pProxyFileList[0]->pStubVtblList == (PCInterfaceStubVtblList *) &cstub_StubVtblList, "stub vtbllist not the same\n"); + ok(proxy_vtbl == (PCInterfaceProxyVtblList *) &cstub_ProxyVtblList, "proxy vtbllist not the same\n"); + ok(stub_vtbl == (PCInterfaceStubVtblList *) &cstub_StubVtblList, "stub vtbllist not the same\n"); /* if1 is non-delegating, if2 is delegating, if3 is non-delegating but I've zero'ed the vtbl entries, similarly if4 is delegating with zero'ed vtbl entries */ #define VTBL_TEST_NOT_CHANGE_TO(name, i) \ - ok(PSFactoryBuffer.pProxyFileList[0]->pStubVtblList[i]->Vtbl.name != CStd_##name, #name "vtbl %d updated %p %p\n", \ - i, PSFactoryBuffer.pProxyFileList[0]->pStubVtblList[i]->Vtbl.name, CStd_##name ); + ok(stub_vtbl[i]->Vtbl.name != CStd_##name, #name "vtbl %d updated %p %p\n", \ + i, stub_vtbl[i]->Vtbl.name, CStd_##name ) #define VTBL_TEST_CHANGE_TO(name, i) \ - ok(PSFactoryBuffer.pProxyFileList[0]->pStubVtblList[i]->Vtbl.name == CStd_##name, #name "vtbl %d not updated %p %p\n", \ - i, PSFactoryBuffer.pProxyFileList[0]->pStubVtblList[i]->Vtbl.name, CStd_##name ); + ok(stub_vtbl[i]->Vtbl.name == CStd_##name, #name "vtbl %d not updated %p %p\n", \ + i, stub_vtbl[i]->Vtbl.name, CStd_##name ) #define VTBL_TEST_ZERO(name, i) \ - ok(PSFactoryBuffer.pProxyFileList[0]->pStubVtblList[i]->Vtbl.name == NULL, #name "vtbl %d not null %p\n", \ - i, PSFactoryBuffer.pProxyFileList[0]->pStubVtblList[i]->Vtbl.name ); + ok(stub_vtbl[i]->Vtbl.name == NULL, #name "vtbl %d not null %p\n", \ + i, stub_vtbl[i]->Vtbl.name ) + VTBL_TEST_NOT_CHANGE_TO(QueryInterface, 0); VTBL_TEST_NOT_CHANGE_TO(AddRef, 0); VTBL_TEST_NOT_CHANGE_TO(Release, 0); @@ -517,11 +527,55 @@ static IPSFactoryBuffer *test_NdrDllGetClassObject(void) VTBL_TEST_CHANGE_TO(DebugServerQueryInterface, 3); VTBL_TEST_CHANGE_TO(DebugServerRelease, 3); - +#define VTBL_PROXY_TEST(i,num,ptr) \ + ok( proxy_vtbl[i]->Vtbl[num] == (ptr), "wrong proxy %u func %u %p/%p\n", \ + (i), (num), proxy_vtbl[i]->Vtbl[num], (ptr) ) +#define VTBL_PROXY_TEST_NOT_ZERO(i,num) \ + ok( proxy_vtbl[i]->Vtbl[num] != NULL, "wrong proxy %u func %u is NULL\n", (i), (num)) + + VTBL_PROXY_TEST(0, 0, IUnknown_QueryInterface_Proxy); + VTBL_PROXY_TEST(0, 1, IUnknown_AddRef_Proxy); + VTBL_PROXY_TEST(0, 2, IUnknown_Release_Proxy); + VTBL_PROXY_TEST(0, 3, if1_fn1_Proxy); + VTBL_PROXY_TEST(0, 4, if1_fn2_Proxy); + + VTBL_PROXY_TEST(1, 0, GetProcAddress(rpcrt4,"IUnknown_QueryInterface_Proxy")); + VTBL_PROXY_TEST(1, 1, GetProcAddress(rpcrt4,"IUnknown_AddRef_Proxy")); + VTBL_PROXY_TEST(1, 2, GetProcAddress(rpcrt4,"IUnknown_Release_Proxy")); + VTBL_PROXY_TEST_NOT_ZERO(1, 3); + VTBL_PROXY_TEST_NOT_ZERO(1, 4); + VTBL_PROXY_TEST_NOT_ZERO(1, 5); + VTBL_PROXY_TEST_NOT_ZERO(1, 6); + VTBL_PROXY_TEST_NOT_ZERO(1, 7); + VTBL_PROXY_TEST_NOT_ZERO(1, 8); + VTBL_PROXY_TEST_NOT_ZERO(1, 9); + VTBL_PROXY_TEST_NOT_ZERO(1, 10); + VTBL_PROXY_TEST_NOT_ZERO(1, 11); + VTBL_PROXY_TEST_NOT_ZERO(1, 12); + + VTBL_PROXY_TEST(2, 0, IUnknown_QueryInterface_Proxy); + VTBL_PROXY_TEST(2, 1, IUnknown_AddRef_Proxy); + VTBL_PROXY_TEST(2, 2, IUnknown_Release_Proxy); + VTBL_PROXY_TEST(2, 3, if1_fn1_Proxy); + todo_wine VTBL_PROXY_TEST_NOT_ZERO(2, 4); + + VTBL_PROXY_TEST(3, 0, GetProcAddress(rpcrt4,"IUnknown_QueryInterface_Proxy")); + VTBL_PROXY_TEST(3, 1, GetProcAddress(rpcrt4,"IUnknown_AddRef_Proxy")); + VTBL_PROXY_TEST(3, 2, GetProcAddress(rpcrt4,"IUnknown_Release_Proxy")); + VTBL_PROXY_TEST_NOT_ZERO(3, 3); + VTBL_PROXY_TEST_NOT_ZERO(3, 4); + VTBL_PROXY_TEST_NOT_ZERO(3, 5); + VTBL_PROXY_TEST_NOT_ZERO(3, 6); #undef VTBL_TEST_NOT_CHANGE_TO #undef VTBL_TEST_CHANGE_TO #undef VTBL_TEST_ZERO +#undef VTBL_PROXY_TEST +#undef VTBL_PROXY_TEST_NOT_ZERO + + for (i = 0; i < sizeof(interfaces)/sizeof(interfaces[0]); i++) + ok( proxy_vtbl[i]->header.piid == interfaces[i], + "wrong proxy %u iid %p/%p\n", i, proxy_vtbl[i]->header.piid, interfaces[i] ); ok(PSFactoryBuffer.RefCount == 1, "ref count %d\n", PSFactoryBuffer.RefCount); IPSFactoryBuffer_Release(ppsf);
1
0
0
0
Alexandre Julliard : rpcrt4: Add support for proxy delegation.
by Alexandre Julliard
04 Jun '09
04 Jun '09
Module: wine Branch: master Commit: 3c9571df781d8e10a8e58f240db25e3ec715144b URL:
http://source.winehq.org/git/wine.git/?a=commit;h=3c9571df781d8e10a8e58f240…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Jun 3 16:42:50 2009 +0200 rpcrt4: Add support for proxy delegation. --- dlls/rpcrt4/cproxy.c | 27 +++++++++++++++++++++++++-- dlls/rpcrt4/cpsf.c | 5 +++++ dlls/rpcrt4/cpsf.h | 2 ++ dlls/rpcrt4/cstub.c | 25 +++++++++++++++++++++++++ dlls/rpcrt4/ndr_ole.c | 24 ++++++++++++++++++++++++ 5 files changed, 81 insertions(+), 2 deletions(-) diff --git a/dlls/rpcrt4/cproxy.c b/dlls/rpcrt4/cproxy.c index 887de87..6461612 100644 --- a/dlls/rpcrt4/cproxy.c +++ b/dlls/rpcrt4/cproxy.c @@ -2,6 +2,7 @@ * COM proxy implementation * * Copyright 2001 Ove Kåven, TransGaming Technologies + * Copyright 2009 Alexandre Julliard * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -48,6 +49,8 @@ typedef struct { LONG RefCount; const IID* piid; LPUNKNOWN pUnkOuter; + IUnknown *base_object; /* must be at offset 0x10 from PVtbl */ + IRpcProxyBuffer *base_proxy; PCInterfaceName name; LPPSFACTORYBUFFER pPSFactory; LPRPCCHANNELBUFFER pChannel; @@ -172,8 +175,6 @@ HRESULT StdProxy_Construct(REFIID riid, fill_stubless_table( (IUnknownVtbl *)vtbl->Vtbl, count ); } - TRACE("iid=%s vtbl=%p\n", debugstr_guid(vtbl->header.piid), vtbl->Vtbl); - if (!IsEqualGUID(vtbl->header.piid, riid)) { ERR("IID mismatch during proxy creation\n"); return RPC_E_UNEXPECTED; @@ -188,15 +189,31 @@ HRESULT StdProxy_Construct(REFIID riid, /* one reference for the proxy */ This->RefCount = 1; This->piid = vtbl->header.piid; + This->base_object = NULL; + This->base_proxy = NULL; This->pUnkOuter = pUnkOuter; This->name = name; This->pPSFactory = pPSFactory; This->pChannel = NULL; + + if(ProxyInfo->pDelegatedIIDs && ProxyInfo->pDelegatedIIDs[Index]) + { + HRESULT r = create_proxy( ProxyInfo->pDelegatedIIDs[Index], NULL, + &This->base_proxy, (void **)&This->base_object ); + if (FAILED(r)) + { + HeapFree( GetProcessHeap(), 0, This ); + return r; + } + } + *ppProxy = (LPRPCPROXYBUFFER)&This->lpVtbl; *ppvObj = &This->PVtbl; IUnknown_AddRef((IUnknown *)*ppvObj); IPSFactoryBuffer_AddRef(pPSFactory); + TRACE( "iid=%s this %p proxy %p obj %p vtbl %p base proxy %p base obj %p\n", + debugstr_guid(riid), This, *ppProxy, *ppvObj, This->PVtbl, This->base_proxy, This->base_object ); return S_OK; } @@ -207,6 +224,9 @@ static void StdProxy_Destruct(LPRPCPROXYBUFFER iface) if (This->pChannel) IRpcProxyBuffer_Disconnect(iface); + if (This->base_object) IUnknown_Release( This->base_object ); + if (This->base_proxy) IRpcProxyBuffer_Release( This->base_proxy ); + IPSFactoryBuffer_Release(This->pPSFactory); HeapFree(GetProcessHeap(),0,This); } @@ -262,6 +282,7 @@ static HRESULT WINAPI StdProxy_Connect(LPRPCPROXYBUFFER iface, This->pChannel = pChannel; IRpcChannelBuffer_AddRef(pChannel); + if (This->base_proxy) IRpcProxyBuffer_Connect( This->base_proxy, pChannel ); return S_OK; } @@ -270,6 +291,8 @@ static VOID WINAPI StdProxy_Disconnect(LPRPCPROXYBUFFER iface) ICOM_THIS_MULTI(StdProxyImpl,lpVtbl,iface); TRACE("(%p)->Disconnect()\n",This); + if (This->base_proxy) IRpcProxyBuffer_Disconnect( This->base_proxy ); + IRpcChannelBuffer_Release(This->pChannel); This->pChannel = NULL; } diff --git a/dlls/rpcrt4/cpsf.c b/dlls/rpcrt4/cpsf.c index 6d94580..fe55185 100644 --- a/dlls/rpcrt4/cpsf.c +++ b/dlls/rpcrt4/cpsf.c @@ -155,6 +155,7 @@ static void init_psfactory( CStdPSFactoryBuffer *psfac, const ProxyFileInfo **fi psfac->pProxyFileList = file_list; for (i = 0; file_list[i]; i++) { + const PCInterfaceProxyVtblList *proxies = file_list[i]->pProxyVtblList; const PCInterfaceStubVtblList *stubs = file_list[i]->pStubVtblList; for (j = 0; j < file_list[i]->TableSize; j++) @@ -165,7 +166,11 @@ static void init_psfactory( CStdPSFactoryBuffer *psfac, const ProxyFileInfo **fi void **pRpcStubVtbl = (void **)&stubs[j]->Vtbl; if (file_list[i]->pDelegatedIIDs && file_list[i]->pDelegatedIIDs[j]) + { + fill_delegated_proxy_table( (IUnknownVtbl *)proxies[j]->Vtbl, + stubs[j]->header.DispatchTableCount ); pSrcRpcStubVtbl = (void * const *)&CStdStubBuffer_Delegating_Vtbl; + } for (k = 0; k < sizeof(IRpcStubBufferVtbl)/sizeof(void *); k++) if (!pRpcStubVtbl[k]) pRpcStubVtbl[k] = pSrcRpcStubVtbl[k]; diff --git a/dlls/rpcrt4/cpsf.h b/dlls/rpcrt4/cpsf.h index 58645fb..9cc046f 100644 --- a/dlls/rpcrt4/cpsf.h +++ b/dlls/rpcrt4/cpsf.h @@ -38,6 +38,8 @@ const MIDL_SERVER_INFO *CStdStubBuffer_GetServerInfo(IRpcStubBuffer *iface); const IRpcStubBufferVtbl CStdStubBuffer_Vtbl; const IRpcStubBufferVtbl CStdStubBuffer_Delegating_Vtbl; +BOOL fill_delegated_proxy_table(IUnknownVtbl *vtbl, DWORD num); +HRESULT create_proxy(REFIID iid, IUnknown *pUnkOuter, IRpcProxyBuffer **pproxy, void **ppv); HRESULT create_stub(REFIID iid, IUnknown *pUnk, IRpcStubBuffer **ppstub); #endif /* __WINE_CPSF_H */ diff --git a/dlls/rpcrt4/cstub.c b/dlls/rpcrt4/cstub.c index 8e947f2..3e1ae8f 100644 --- a/dlls/rpcrt4/cstub.c +++ b/dlls/rpcrt4/cstub.c @@ -2,6 +2,7 @@ * COM stub (CStdStubBuffer) implementation * * Copyright 2001 Ove Kåven, TransGaming Technologies + * Copyright 2009 Alexandre Julliard * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -212,6 +213,24 @@ static BOOL fill_delegated_stub_table(IUnknownVtbl *vtbl, DWORD num) return TRUE; } +BOOL fill_delegated_proxy_table(IUnknownVtbl *vtbl, DWORD num) +{ + const void **entry = (const void **)(vtbl + 1); + DWORD i, j; + + vtbl->QueryInterface = IUnknown_QueryInterface_Proxy; + vtbl->AddRef = IUnknown_AddRef_Proxy; + vtbl->Release = IUnknown_Release_Proxy; + for (i = 0; i < (num - 3 + BLOCK_SIZE - 1) / BLOCK_SIZE; i++) + { + const vtbl_method_t *block = method_blocks[i]; + if (!block && !(block = allocate_block( i ))) return FALSE; + for (j = 0; j < BLOCK_SIZE && j < num - 3 - i * BLOCK_SIZE; j++, entry++) + if (!*entry) *entry = &block[j]; + } + return TRUE; +} + #else /* __i386__ */ static BOOL fill_delegated_stub_table(IUnknownVtbl *vtbl, DWORD num) @@ -220,6 +239,12 @@ static BOOL fill_delegated_stub_table(IUnknownVtbl *vtbl, DWORD num) return FALSE; } +BOOL fill_delegated_proxy_table(IUnknownVtbl *vtbl, DWORD num) +{ + ERR("delegated proxies are not supported on this architecture\n"); + return FALSE; +} + #endif /* __i386__ */ static IUnknownVtbl *get_delegating_vtbl(DWORD num_methods) diff --git a/dlls/rpcrt4/ndr_ole.c b/dlls/rpcrt4/ndr_ole.c index a3264e7..a4c23c2 100644 --- a/dlls/rpcrt4/ndr_ole.c +++ b/dlls/rpcrt4/ndr_ole.c @@ -370,6 +370,30 @@ void WINAPI NdrOleFree(void *NodeToFree) } /*********************************************************************** + * Helper function to create a proxy. + * Probably similar to NdrpCreateProxy. + */ +HRESULT create_proxy(REFIID iid, IUnknown *pUnkOuter, IRpcProxyBuffer **pproxy, void **ppv) +{ + CLSID clsid; + IPSFactoryBuffer *psfac; + HRESULT r; + + if(!LoadCOM()) return E_FAIL; + + r = COM_GetPSClsid( iid, &clsid ); + if(FAILED(r)) return r; + + r = COM_GetClassObject( &clsid, CLSCTX_INPROC_SERVER, NULL, &IID_IPSFactoryBuffer, (void**)&psfac ); + if(FAILED(r)) return r; + + r = IPSFactoryBuffer_CreateProxy(psfac, pUnkOuter, iid, pproxy, ppv); + + IPSFactoryBuffer_Release(psfac); + return r; +} + +/*********************************************************************** * Helper function to create a stub. * This probably looks very much like NdrpCreateStub. */
1
0
0
0
Alexandre Julliard : rpcrt4: Split the vtbl initialization in NdrDllGetClassObject to a separate function .
by Alexandre Julliard
04 Jun '09
04 Jun '09
Module: wine Branch: master Commit: 01d00d178e32de3aaf143e3689f5b661143299d1 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=01d00d178e32de3aaf143e368…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Wed Jun 3 16:39:25 2009 +0200 rpcrt4: Split the vtbl initialization in NdrDllGetClassObject to a separate function. --- dlls/rpcrt4/cpsf.c | 54 +++++++++++++++++++++++++++++---------------------- 1 files changed, 31 insertions(+), 23 deletions(-) diff --git a/dlls/rpcrt4/cpsf.c b/dlls/rpcrt4/cpsf.c index 5d7ffe7..6d94580 100644 --- a/dlls/rpcrt4/cpsf.c +++ b/dlls/rpcrt4/cpsf.c @@ -145,6 +145,35 @@ static const IPSFactoryBufferVtbl CStdPSFactory_Vtbl = CStdPSFactory_CreateStub }; + +static void init_psfactory( CStdPSFactoryBuffer *psfac, const ProxyFileInfo **file_list ) +{ + DWORD i, j, k; + + psfac->lpVtbl = &CStdPSFactory_Vtbl; + psfac->RefCount = 0; + psfac->pProxyFileList = file_list; + for (i = 0; file_list[i]; i++) + { + const PCInterfaceStubVtblList *stubs = file_list[i]->pStubVtblList; + + for (j = 0; j < file_list[i]->TableSize; j++) + { + /* FIXME: i think that different vtables should be copied for + * async interfaces */ + void * const *pSrcRpcStubVtbl = (void * const *)&CStdStubBuffer_Vtbl; + void **pRpcStubVtbl = (void **)&stubs[j]->Vtbl; + + if (file_list[i]->pDelegatedIIDs && file_list[i]->pDelegatedIIDs[j]) + pSrcRpcStubVtbl = (void * const *)&CStdStubBuffer_Delegating_Vtbl; + + for (k = 0; k < sizeof(IRpcStubBufferVtbl)/sizeof(void *); k++) + if (!pRpcStubVtbl[k]) pRpcStubVtbl[k] = pSrcRpcStubVtbl[k]; + } + } +} + + /*********************************************************************** * NdrDllGetClassObject [RPCRT4.@] */ @@ -158,29 +187,8 @@ HRESULT WINAPI NdrDllGetClassObject(REFCLSID rclsid, REFIID iid, LPVOID *ppv, pPSFactoryBuffer); *ppv = NULL; - if (!pPSFactoryBuffer->lpVtbl) { - const ProxyFileInfo **pProxyFileList2; - pPSFactoryBuffer->lpVtbl = &CStdPSFactory_Vtbl; - pPSFactoryBuffer->RefCount = 0; - pPSFactoryBuffer->pProxyFileList = pProxyFileList; - for (pProxyFileList2 = pProxyFileList; *pProxyFileList2; pProxyFileList2++) { - int i; - for (i = 0; i < (*pProxyFileList2)->TableSize; i++) { - /* FIXME: i think that different vtables should be copied for - * async interfaces */ - void * const *pSrcRpcStubVtbl = (void * const *)&CStdStubBuffer_Vtbl; - void **pRpcStubVtbl = (void **)&(*pProxyFileList2)->pStubVtblList[i]->Vtbl; - unsigned int j; - - if ((*pProxyFileList2)->pDelegatedIIDs && (*pProxyFileList2)->pDelegatedIIDs[i]) - pSrcRpcStubVtbl = (void * const *)&CStdStubBuffer_Delegating_Vtbl; - - for (j = 0; j < sizeof(IRpcStubBufferVtbl)/sizeof(void *); j++) - if (!pRpcStubVtbl[j]) - pRpcStubVtbl[j] = pSrcRpcStubVtbl[j]; - } - } - } + if (!pPSFactoryBuffer->lpVtbl) init_psfactory( pPSFactoryBuffer, pProxyFileList ); + if (pclsid && IsEqualGUID(rclsid, pclsid)) return IPSFactoryBuffer_QueryInterface((LPPSFACTORYBUFFER)pPSFactoryBuffer, iid, ppv); else {
1
0
0
0
Zachary Goldberg : WWN Issue 358
by Jeremy Newman
03 Jun '09
03 Jun '09
Module: website Branch: master Commit: 6009fab8ce86eb6f279b2c730270e691d68ab7b5 URL:
http://source.winehq.org/git/website.git/?a=commit;h=6009fab8ce86eb6f279b2c…
Author: Zachary Goldberg <zgold(a)bluesata.com> Date: Wed Jun 3 10:02:43 2009 -0500 WWN Issue 358 --- news/en/2009060301.xml | 17 + wwn/en/wn20090603_358.xml | 1223 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 1240 insertions(+), 0 deletions(-) Diff:
http://source.winehq.org/git/website.git/?a=commitdiff;h=6009fab8ce86eb6f27…
1
0
0
0
Austin Lund : riched20/test: Added a test for TxDraw.
by Alexandre Julliard
03 Jun '09
03 Jun '09
Module: wine Branch: master Commit: 1643679476c88953c6c506c152c7d25ba2219716 URL:
http://source.winehq.org/git/wine.git/?a=commit;h=1643679476c88953c6c506c15…
Author: Austin Lund <austin.lund(a)gmail.com> Date: Wed Jun 3 16:02:56 2009 +1000 riched20/test: Added a test for TxDraw. --- dlls/riched20/tests/txtsrv.c | 26 ++++++++++++++++++++++++++ 1 files changed, 26 insertions(+), 0 deletions(-) diff --git a/dlls/riched20/tests/txtsrv.c b/dlls/riched20/tests/txtsrv.c index e4d6ae4..da28945 100644 --- a/dlls/riched20/tests/txtsrv.c +++ b/dlls/riched20/tests/txtsrv.c @@ -739,6 +739,31 @@ static void test_TxGetNaturalSize(void) { CoTaskMemFree(dummyTextHost); } +static void test_TxDraw(void) +{ + HDC tmphdc = GetDC(NULL); + DWORD dwAspect = DVASPECT_CONTENT; + HDC hicTargetDev = NULL; /* Means "default" device */ + DVTARGETDEVICE *ptd = NULL; + void *pvAspect = NULL; + HRESULT result; + RECTL client = {0,0,100,100}; + + if (!init_texthost()) + return; + + todo_wine { + result = ITextServices_TxDraw(txtserv, dwAspect, 0, pvAspect, ptd, + tmphdc, hicTargetDev, &client, NULL, + NULL, NULL, 0, 0); + ok(result == S_OK, "TxDraw failed\n"); + } + + IUnknown_Release(txtserv); + CoTaskMemFree(dummyTextHost); + +} + START_TEST( txtsrv ) { setup_thiscall_wrappers(); @@ -756,6 +781,7 @@ START_TEST( txtsrv ) test_TxGetText(); test_TxSetText(); test_TxGetNaturalSize(); + test_TxDraw(); } if (wrapperCodeMem) VirtualFree(wrapperCodeMem, 0, MEM_RELEASE); }
1
0
0
0
← Newer
1
...
94
95
96
97
98
99
100
...
112
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
Results per page:
10
25
50
100
200