winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
July
June
May
April
March
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
April 2022
----- 2025 -----
July 2025
June 2025
May 2025
April 2025
March 2025
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
1024 discussions
Start a n
N
ew thread
Huw Davies : user32: Set WM_CONTEXTMENU's wparam to the child window's handle.
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: 149284628def87f7e1ca70a1f8c7858d68cea346 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=149284628def87f7e1ca70a1…
Author: Huw Davies <huw(a)codeweavers.com> Date: Fri Jan 7 08:46:36 2022 +0000 user32: Set WM_CONTEXTMENU's wparam to the child window's handle. DefWindowProc() does not propagate the wparam; it updates it instead. Spotted by YAL. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=52327
Signed-off-by: Huw Davies <huw(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit 3af8415ca9dc50e6c394c1001aad97db5f514069) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/user32/defwnd.c | 2 +- dlls/user32/tests/msg.c | 29 +++++++++++++++++++++++++++-- 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/dlls/user32/defwnd.c b/dlls/user32/defwnd.c index d00fc8584c6..ae61ae01c5d 100644 --- a/dlls/user32/defwnd.c +++ b/dlls/user32/defwnd.c @@ -311,7 +311,7 @@ static LRESULT DEFWND_DefWinProc( HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPa case WM_CONTEXTMENU: if (GetWindowLongW( hwnd, GWL_STYLE ) & WS_CHILD) - SendMessageW( GetParent(hwnd), msg, wParam, lParam ); + SendMessageW( GetParent(hwnd), msg, (WPARAM)hwnd, lParam ); else { LONG hitcode; diff --git a/dlls/user32/tests/msg.c b/dlls/user32/tests/msg.c index 7eaa2c67945..58fe2c7ace1 100644 --- a/dlls/user32/tests/msg.c +++ b/dlls/user32/tests/msg.c @@ -106,6 +106,7 @@ typedef struct } MEASURE_ITEM_STRUCT; static BOOL test_DestroyWindow_flag; +static BOOL test_context_menu; static HWINEVENTHOOK hEvent_hook; static HHOOK hKBD_hook; static HHOOK hCBT_hook; @@ -9787,7 +9788,7 @@ static LRESULT MsgCheckProc (BOOL unicode, HWND hwnd, UINT message, return 0; } - if (message == WM_CONTEXTMENU) + if (!test_context_menu && message == WM_CONTEXTMENU) { /* don't create context menu */ return 0; @@ -15765,6 +15766,13 @@ static const struct message WmRestoreActiveMinimizedOverlappedSeq[] = { 0 } }; +static struct message WmContextMenuSeq[] = { + { WM_CONTEXTMENU, sent|wparam, 0 }, /* wparams set in the code */ + { WM_CONTEXTMENU, sent|wparam|defwinproc, 0 }, + { WM_CONTEXTMENU, sent|wparam|defwinproc, 0 }, + { 0 } +}; + struct rbuttonup_thread_data { HWND hwnd; @@ -15786,7 +15794,7 @@ static DWORD CALLBACK post_rbuttonup_msg( void *arg ) static void test_defwinproc(void) { - HWND hwnd; + HWND hwnd, child[3]; MSG msg; BOOL gotwmquit = FALSE; POINT pos; @@ -15836,6 +15844,23 @@ static void test_defwinproc(void) flush_events(); ok_sequence(WmRestoreActiveMinimizedOverlappedSeq, "DefWindowProcA(SC_RESTORE):active minimized overlapped", TRUE); + child[0] = CreateWindowExA(0, "TestWindowClass", "1st child", + WS_VISIBLE | WS_CHILD, 0,0,500,100, hwnd, 0, 0, NULL); + child[1] = CreateWindowExA(0, "TestWindowClass", "2nd child", + WS_VISIBLE | WS_CHILD, 0,0,500,100, child[0], 0, 0, NULL); + child[2] = CreateWindowExA(0, "TestWindowClass", "3rd child", + WS_VISIBLE | WS_CHILD, 0,0,500,100, child[1], 0, 0, NULL); + flush_events(); + flush_sequence(); + test_context_menu = TRUE; + DefWindowProcA(child[2], WM_CONTEXTMENU, 0xcafe, 0); + test_context_menu = FALSE; + WmContextMenuSeq[0].wParam = (WPARAM)child[2]; + WmContextMenuSeq[1].wParam = (WPARAM)child[1]; + WmContextMenuSeq[2].wParam = (WPARAM)child[0]; + ok_sequence(WmContextMenuSeq, "DefWindowProcA(WM_CONTEXTMENU)", FALSE); + DestroyWindow(child[0]); + GetCursorPos(&pos); GetWindowRect(hwnd, &rect); x = (rect.left+rect.right) / 2;
1
0
0
0
Nikolay Sivov : d3d11: Always initialize out view pointer in CreateRenderTargetView().
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: 3ce233678847647b1f0866638d66b2ab384a3f51 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=3ce233678847647b1f086663…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Sat Jan 8 16:03:08 2022 +0300 d3d11: Always initialize out view pointer in CreateRenderTargetView(). Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=51195
Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit df8ef3a54fa87802932343cf8ad4e48fee375526) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/d3d10core/tests/d3d10core.c | 4 ++++ dlls/d3d11/device.c | 4 ++++ dlls/d3d11/tests/d3d11.c | 4 ++++ 3 files changed, 12 insertions(+) diff --git a/dlls/d3d10core/tests/d3d10core.c b/dlls/d3d10core/tests/d3d10core.c index 4332ce2dcf2..83bd8596a22 100644 --- a/dlls/d3d10core/tests/d3d10core.c +++ b/dlls/d3d10core/tests/d3d10core.c @@ -2937,8 +2937,10 @@ static void test_create_rendertarget_view(void) if (!enable_debug_layer) { + rtview = (void *)0xdeadbeef; hr = ID3D10Device_CreateRenderTargetView(device, NULL, &rtv_desc, &rtview); ok(hr == E_INVALIDARG, "Got unexpected hr %#x.\n", hr); + ok(!rtview, "Unexpected pointer %p.\n", rtview); } expected_refcount = get_refcount(device) + 1; @@ -3055,8 +3057,10 @@ static void test_create_rendertarget_view(void) } get_rtv_desc(&rtv_desc, &invalid_desc_tests[i].rtv_desc); + rtview = (void *)0xdeadbeef; hr = ID3D10Device_CreateRenderTargetView(device, texture, &rtv_desc, &rtview); ok(hr == E_INVALIDARG, "Test %u: Got unexpected hr %#x.\n", i, hr); + ok(!rtview, "Unexpected pointer %p.\n", rtview); ID3D10Resource_Release(texture); } diff --git a/dlls/d3d11/device.c b/dlls/d3d11/device.c index e870399a83e..187ff1fd7b5 100644 --- a/dlls/d3d11/device.c +++ b/dlls/d3d11/device.c @@ -3054,6 +3054,8 @@ static HRESULT STDMETHODCALLTYPE d3d11_device_CreateRenderTargetView(ID3D11Devic TRACE("iface %p, resource %p, desc %p, view %p.\n", iface, resource, desc, view); + *view = NULL; + if (!resource) return E_INVALIDARG; @@ -5554,6 +5556,8 @@ static HRESULT STDMETHODCALLTYPE d3d10_device_CreateRenderTargetView(ID3D10Devic TRACE("iface %p, resource %p, desc %p, view %p.\n", iface, resource, desc, view); + *view = NULL; + if (!resource) return E_INVALIDARG; diff --git a/dlls/d3d11/tests/d3d11.c b/dlls/d3d11/tests/d3d11.c index 80fbc66e3fd..f03280f9a71 100644 --- a/dlls/d3d11/tests/d3d11.c +++ b/dlls/d3d11/tests/d3d11.c @@ -3936,8 +3936,10 @@ static void test_create_rendertarget_view(void) if (!enable_debug_layer) { + rtview = (void *)0xdeadbeef; hr = ID3D11Device_CreateRenderTargetView(device, NULL, &rtv_desc, &rtview); ok(hr == E_INVALIDARG, "Got unexpected hr %#x.\n", hr); + ok(!rtview, "Unexpected pointer %p.\n", rtview); } expected_refcount = get_refcount(device) + 1; @@ -4054,8 +4056,10 @@ static void test_create_rendertarget_view(void) } get_rtv_desc(&rtv_desc, &invalid_desc_tests[i].rtv_desc); + rtview = (void *)0xdeadbeef; hr = ID3D11Device_CreateRenderTargetView(device, texture, &rtv_desc, &rtview); ok(hr == E_INVALIDARG, "Test %u: Got unexpected hr %#x.\n", i, hr); + ok(!rtview, "Unexpected pointer %p.\n", rtview); ID3D11Resource_Release(texture); }
1
0
0
0
Jacek Konieczny : winealsa.drv: Use separate port for each output device.
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: c03499e8eca2a0171bb23966a5727ada351152de URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c03499e8eca2a0171bb23966…
Author: Jacek Konieczny <jajcus(a)jajcus.net> Date: Sun Dec 19 15:20:28 2021 +0100 winealsa.drv: Use separate port for each output device. This fixes use of multiple MIDI outputs while keeping the flexibility of proper ALSA sequencer port subscriptions. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=52220
Signed-off-by: Jacek Konieczny <jajcus(a)jajcus.net> Signed-off-by: Andrew Eikum <aeikum(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit 240f2f39632a08d81e8133dde20b441d8378ed0f) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/winealsa.drv/midi.c | 55 +++++++++++++++++++++++++++++++++--------------- 1 file changed, 38 insertions(+), 17 deletions(-) diff --git a/dlls/winealsa.drv/midi.c b/dlls/winealsa.drv/midi.c index f2fe6307bb2..ac666b49d79 100644 --- a/dlls/winealsa.drv/midi.c +++ b/dlls/winealsa.drv/midi.c @@ -85,6 +85,7 @@ typedef struct { void* lpExtra; /* according to port type (MIDI, FM...), extra data when needed */ MIDIOUTCAPSW caps; snd_seq_addr_t addr; + int port_out; } WINE_MIDIOUT; static WINE_MIDIIN MidiInDev [MAX_MIDIINDRV ]; @@ -108,7 +109,6 @@ static int numOpenMidiSeq = 0; static int numStartedMidiIn = 0; static int port_in; -static int port_out; static CRITICAL_SECTION crit_sect; /* protects all MidiIn buffer queues */ static CRITICAL_SECTION_DEBUG critsect_debug = @@ -247,14 +247,6 @@ static int midiOpenSeq(BOOL create_client) /* Setting the client name is the only init to do */ snd_seq_set_client_name(midiSeq, "WINE midi driver"); - port_out = snd_seq_create_simple_port(midiSeq, "WINE ALSA Output", - SND_SEQ_PORT_CAP_READ|SND_SEQ_PORT_CAP_SUBS_READ|SND_SEQ_PORT_CAP_SUBS_WRITE, - SND_SEQ_PORT_TYPE_MIDI_GENERIC|SND_SEQ_PORT_TYPE_APPLICATION); - if (port_out < 0) - TRACE("Unable to create output port\n"); - else - TRACE("Outport port %d created successfully\n", port_out); - port_in = snd_seq_create_simple_port(midiSeq, "WINE ALSA Input", SND_SEQ_PORT_CAP_WRITE|SND_SEQ_PORT_CAP_SUBS_READ|SND_SEQ_PORT_CAP_SUBS_WRITE, SND_SEQ_PORT_TYPE_MIDI_GENERIC|SND_SEQ_PORT_TYPE_APPLICATION); @@ -276,7 +268,6 @@ static int midiCloseSeq(void) { EnterCriticalSection(&midiSeqLock); if (--numOpenMidiSeq == 0) { - snd_seq_delete_simple_port(midiSeq, port_out); snd_seq_delete_simple_port(midiSeq, port_in); snd_seq_close(midiSeq); midiSeq = NULL; @@ -738,6 +729,8 @@ static DWORD modGetDevCaps(WORD wDevID, LPMIDIOUTCAPSW lpCaps, DWORD dwSize) static DWORD modOpen(WORD wDevID, LPMIDIOPENDESC lpDesc, DWORD dwFlags) { int ret; + int port_out; + char port_out_name[32]; TRACE("(%04X, %p, %08X);\n", wDevID, lpDesc, dwFlags); if (lpDesc == NULL) { @@ -784,12 +777,37 @@ static DWORD modOpen(WORD wDevID, LPMIDIOPENDESC lpDesc, DWORD dwFlags) MidiOutDev[wDevID].bufsize = 0x3FFF; MidiOutDev[wDevID].midiDesc = *lpDesc; - /* Connect our app port to the device port */ EnterCriticalSection(&midiSeqLock); - ret = snd_seq_connect_to(midiSeq, port_out, MidiOutDev[wDevID].addr.client, - MidiOutDev[wDevID].addr.port); + /* Create a port dedicated to a specific device */ + /* Keep the old name without a number for the first port */ + if (wDevID) + sprintf(port_out_name, "WINE ALSA Output #%d", wDevID); + + port_out = snd_seq_create_simple_port(midiSeq, wDevID?port_out_name:"WINE ALSA Output", + SND_SEQ_PORT_CAP_READ|SND_SEQ_PORT_CAP_SUBS_READ|SND_SEQ_PORT_CAP_SUBS_WRITE, + SND_SEQ_PORT_TYPE_MIDI_GENERIC|SND_SEQ_PORT_TYPE_APPLICATION); + + if (port_out < 0) { + TRACE("Unable to create output port\n"); + MidiOutDev[wDevID].port_out = -1; + } else { + TRACE("Outport port %d created successfully\n", port_out); + MidiOutDev[wDevID].port_out = port_out; + + /* Connect our app port to the device port */ + ret = snd_seq_connect_to(midiSeq, port_out, MidiOutDev[wDevID].addr.client, + MidiOutDev[wDevID].addr.port); + + /* usually will happen when the port is already connected */ + /* other errors should not be fatal either */ + if (ret < 0) + WARN("Could not connect port %d to %d:%d: %s\n", + wDevID, MidiOutDev[wDevID].addr.client, + MidiOutDev[wDevID].addr.port, snd_strerror(ret)); + } LeaveCriticalSection(&midiSeqLock); - if (ret < 0) + + if (port_out < 0) return MMSYSERR_NOTENABLED; TRACE("Output port :%d connected %d:%d\n",port_out,MidiOutDev[wDevID].addr.client,MidiOutDev[wDevID].addr.port); @@ -825,7 +843,9 @@ static DWORD modClose(WORD wDevID) case MOD_MIDIPORT: case MOD_SYNTH: EnterCriticalSection(&midiSeqLock); - snd_seq_disconnect_to(midiSeq, port_out, MidiOutDev[wDevID].addr.client, MidiOutDev[wDevID].addr.port); + TRACE("Deleting port :%d, connected to %d:%d\n", MidiOutDev[wDevID].port_out, MidiOutDev[wDevID].addr.client, MidiOutDev[wDevID].addr.port); + snd_seq_delete_simple_port(midiSeq, MidiOutDev[wDevID].port_out); + MidiOutDev[wDevID].port_out = -1; LeaveCriticalSection(&midiSeqLock); midiCloseSeq(); break; @@ -870,7 +890,7 @@ static DWORD modData(WORD wDevID, DWORD dwParam) snd_seq_event_t event; snd_seq_ev_clear(&event); snd_seq_ev_set_direct(&event); - snd_seq_ev_set_source(&event, port_out); + snd_seq_ev_set_source(&event, MidiOutDev[wDevID].port_out); snd_seq_ev_set_subs(&event); switch (evt & 0xF0) { @@ -1039,7 +1059,7 @@ static DWORD modLongData(WORD wDevID, LPMIDIHDR lpMidiHdr, DWORD dwSize) } snd_seq_ev_clear(&event); snd_seq_ev_set_direct(&event); - snd_seq_ev_set_source(&event, port_out); + snd_seq_ev_set_source(&event, MidiOutDev[wDevID].port_out); snd_seq_ev_set_subs(&event); snd_seq_ev_set_sysex(&event, lpMidiHdr->dwBufferLength + len_add, lpNewData ? lpNewData : lpData); EnterCriticalSection(&midiSeqLock); @@ -1201,6 +1221,7 @@ static void ALSA_AddMidiPort(snd_seq_client_info_t* cinfo, snd_seq_port_info_t* MidiOutDev[MODM_NumDevs].caps.wNotes = 16; } MidiOutDev[MODM_NumDevs].bEnabled = TRUE; + MidiOutDev[MODM_NumDevs].port_out = -1; TRACE("MidiOut[%d]\tname='%s' techn=%d voices=%d notes=%d chnMsk=%04x support=%d\n" "\tALSA info: midi dev-type=%x, capa=0\n",
1
0
0
0
Jacek Caban : ntdll: Fix handling \\.\CON path in RtlDosPathNameToNtPathName.
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: 2b48e780fec7697b4809571de1a6396482b79181 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=2b48e780fec7697b4809571d…
Author: Jacek Caban <jacek(a)codeweavers.com> Date: Thu Dec 30 15:49:38 2021 +0100 ntdll: Fix handling \\.\CON path in RtlDosPathNameToNtPathName. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=32183
Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit 32b81bfaff734164143343657bb40ea4e2c073e0) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/ntdll/path.c | 4 +++- dlls/ntdll/tests/path.c | 11 +++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/dlls/ntdll/path.c b/dlls/ntdll/path.c index e452c48df33..5dfb5256bdf 100644 --- a/dlls/ntdll/path.c +++ b/dlls/ntdll/path.c @@ -197,7 +197,8 @@ NTSTATUS WINAPI RtlDosPathNameToNtPathName_U_WithStatus(const WCHAR *dos_path, U return STATUS_OBJECT_NAME_INVALID; if (!memcmp(dos_path, global_prefix, sizeof(global_prefix)) || - (!memcmp(dos_path, global_prefix2, sizeof(global_prefix2)) && dos_path[4])) + (!memcmp(dos_path, global_prefix2, sizeof(global_prefix2)) && dos_path[4]) || + !wcsicmp( dos_path, L"\\\\.\\CON" )) { ntpath->Length = wcslen(dos_path) * sizeof(WCHAR); ntpath->MaximumLength = ntpath->Length + sizeof(WCHAR); @@ -205,6 +206,7 @@ NTSTATUS WINAPI RtlDosPathNameToNtPathName_U_WithStatus(const WCHAR *dos_path, U if (!ntpath->Buffer) return STATUS_NO_MEMORY; memcpy( ntpath->Buffer, dos_path, ntpath->MaximumLength ); ntpath->Buffer[1] = '?'; /* change \\?\ to \??\ */ + ntpath->Buffer[2] = '?'; if (file_part) { if ((ptr = wcsrchr( ntpath->Buffer, '\\' )) && ptr[1]) *file_part = ptr + 1; diff --git a/dlls/ntdll/tests/path.c b/dlls/ntdll/tests/path.c index cd6b9d3a623..1be46b5241d 100644 --- a/dlls/ntdll/tests/path.c +++ b/dlls/ntdll/tests/path.c @@ -119,6 +119,8 @@ static void test_RtlIsDosDeviceName_U(void) { "\\\\.\\CON", 8, 6, TRUE }, /* fails on win8 */ { "\\\\.\\con", 8, 6, TRUE }, /* fails on win8 */ { "\\\\.\\CON2", 0, 0 }, + { "\\\\.\\CONIN$", 0, 0 }, + { "\\\\.\\CONOUT$",0, 0 }, { "", 0, 0 }, { "\\\\foo\\nul", 0, 0 }, { "c:\\nul:", 6, 6 }, @@ -434,6 +436,7 @@ static void test_RtlDosPathNameToNtPathName_U(void) const WCHAR *nt; int file_offset; /* offset to file part */ const WCHAR *alt_nt; + BOOL may_fail; } tests[] = { @@ -518,6 +521,9 @@ static void test_RtlDosPathNameToNtPathName_U(void) {L"\\\\.\\foo/.", L"\\??\\foo", 4}, {L"\\\\.\\foo/..", L"\\??\\", -1}, {L"\\\\.\\foo. . ", L"\\??\\foo", 4}, + {L"\\\\.\\CON", L"\\??\\CON", 4, NULL, TRUE}, /* broken on win7 */ + {L"\\\\.\\CONIN$", L"\\??\\CONIN$", 4}, + {L"\\\\.\\CONOUT$", L"\\??\\CONOUT$", 4}, {L"\\\\?", L"\\??\\", -1}, {L"\\\\?\\", L"\\??\\", -1}, @@ -585,6 +591,11 @@ static void test_RtlDosPathNameToNtPathName_U(void) for (i = 0; i < ARRAY_SIZE(tests); ++i) { ret = pRtlDosPathNameToNtPathName_U(tests[i].dos, &nameW, &file_part, NULL); + if (!ret && tests[i].may_fail) + { + win_skip("skipping broken %s\n", debugstr_w(tests[i].dos)); + continue; + } ok(ret == TRUE, "%s: Got %d.\n", debugstr_w(tests[i].dos), ret); if (pRtlDosPathNameToNtPathName_U_WithStatus)
1
0
0
0
Zebediah Figura : ntdll/tests: Add more tests for RtlDosPathNameToNtPathName_U().
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: bd444692a92b3e66b637673299db5ce415bc3427 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=bd444692a92b3e66b6376732…
Author: Zebediah Figura <zfigura(a)codeweavers.com> Date: Tue Feb 2 18:17:13 2021 -0600 ntdll/tests: Add more tests for RtlDosPathNameToNtPathName_U(). Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit f2f69a8799cd4dd6ab6c61845cd17d0df656e6fc) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/ntdll/tests/path.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/dlls/ntdll/tests/path.c b/dlls/ntdll/tests/path.c index 47afaf2aa3a..cd6b9d3a623 100644 --- a/dlls/ntdll/tests/path.c +++ b/dlls/ntdll/tests/path.c @@ -441,6 +441,18 @@ static void test_RtlDosPathNameToNtPathName_U(void) {L"c:/", L"\\??\\c:\\", -1}, {L"c:/foo", L"\\??\\c:\\foo", 7}, {L"c:/foo.", L"\\??\\c:\\foo", 7}, + {L"c:/foo ", L"\\??\\c:\\foo", 7}, + {L"c:/foo . .", L"\\??\\c:\\foo", 7}, + {L"c:/foo.a", L"\\??\\c:\\foo.a", 7}, + {L"c:/foo a", L"\\??\\c:\\foo a", 7}, + {L"c:/foo*", L"\\??\\c:\\foo*", 7}, + {L"c:/foo*a", L"\\??\\c:\\foo*a", 7}, + {L"c:/foo?", L"\\??\\c:\\foo?", 7}, + {L"c:/foo?a", L"\\??\\c:\\foo?a", 7}, + {L"c:/foo<", L"\\??\\c:\\foo<", 7}, + {L"c:/foo<a", L"\\??\\c:\\foo<a", 7}, + {L"c:/foo>", L"\\??\\c:\\foo>", 7}, + {L"c:/foo>a", L"\\??\\c:\\foo>a", 7}, {L"c:/foo/", L"\\??\\c:\\foo\\", -1}, {L"c:/foo//", L"\\??\\c:\\foo\\", -1}, {L"C:/foo", L"\\??\\C:\\foo", 7}, @@ -485,6 +497,7 @@ static void test_RtlDosPathNameToNtPathName_U(void) {L"//./foo/bar", L"\\??\\foo\\bar", 8}, {L"//./foo/.", L"\\??\\foo", 4}, {L"//./foo/..", L"\\??\\", -1}, + {L"//./foo. . ", L"\\??\\foo", 4}, {L"//?", L"\\??\\", -1}, {L"//?/", L"\\??\\", -1}, @@ -494,6 +507,7 @@ static void test_RtlDosPathNameToNtPathName_U(void) {L"//?/foo/bar", L"\\??\\foo\\bar", 8}, {L"//?/foo/.", L"\\??\\foo", 4}, {L"//?/foo/..", L"\\??\\", -1}, + {L"//?/foo. . ", L"\\??\\foo", 4}, {L"\\\\.", L"\\??\\", -1}, {L"\\\\.\\", L"\\??\\", -1}, @@ -503,6 +517,7 @@ static void test_RtlDosPathNameToNtPathName_U(void) {L"\\\\.\\foo/bar", L"\\??\\foo\\bar", 8}, {L"\\\\.\\foo/.", L"\\??\\foo", 4}, {L"\\\\.\\foo/..", L"\\??\\", -1}, + {L"\\\\.\\foo. . ", L"\\??\\foo", 4}, {L"\\\\?", L"\\??\\", -1}, {L"\\\\?\\", L"\\??\\", -1}, @@ -519,6 +534,7 @@ static void test_RtlDosPathNameToNtPathName_U(void) {L"\\\\?\\foo\\bar",L"\\??\\foo\\bar", 8}, {L"\\\\?\\foo\\.", L"\\??\\foo\\.", 8}, {L"\\\\?\\foo\\..", L"\\??\\foo\\..", 8}, + {L"\\\\?\\foo. . ", L"\\??\\foo. . ", 4}, {L"\\??", L"\\??\\C:\\??", 7}, {L"\\??\\", L"\\??\\C:\\??\\", -1}, @@ -535,6 +551,7 @@ static void test_RtlDosPathNameToNtPathName_U(void) {L"\\??\\foo\\bar", L"\\??\\foo\\bar", 8}, {L"\\??\\foo\\.", L"\\??\\foo\\.", 8}, {L"\\??\\foo\\..", L"\\??\\foo\\..", 8}, + {L"\\??\\foo. . ", L"\\??\\foo. . ", 4}, {L"CONIN$", L"\\??\\CONIN$", -1, L"\\??\\C:\\windows\\CONIN$" /* winxp */ }, {L"CONOUT$", L"\\??\\CONOUT$", -1, L"\\??\\C:\\windows\\CONOUT$" /* winxp */ },
1
0
0
0
Bernhard Übelacker : inetmib1: Fix endianess issue with dwLocalAddr and dwLocalPort.
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: 749d5efa7efc5a541f914aed591e75350c72a58c URL:
https://source.winehq.org/git/wine.git/?a=commit;h=749d5efa7efc5a541f914aed…
Author: Bernhard Übelacker <bernhardu(a)mailbox.org> Date: Thu Dec 16 11:27:19 2021 +0100 inetmib1: Fix endianess issue with dwLocalAddr and dwLocalPort. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=52224
Signed-off-by: Bernhard Übelacker <bernhardu(a)mailbox.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit 9145b551b2ebe17c1e310790db5c09da24a1beb5) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/inetmib1/main.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/dlls/inetmib1/main.c b/dlls/inetmib1/main.c index 6345573350e..31dc4d5e8e2 100644 --- a/dlls/inetmib1/main.c +++ b/dlls/inetmib1/main.c @@ -25,6 +25,7 @@ #include "windef.h" #include "winbase.h" +#include "winsock2.h" #include "snmp.h" #include "iphlpapi.h" #include "wine/debug.h" @@ -1217,7 +1218,7 @@ static void oidToUdpRow(AsnObjectIdentifier *oid, void *dst) assert(oid && oid->idLength >= 5); row->dwLocalAddr = oidToIpAddr(oid); - row->dwLocalPort = oid->ids[4]; + row->dwLocalPort = htons(oid->ids[4]); } static int __cdecl compareUdpRow(const void *a, const void *b) @@ -1225,9 +1226,9 @@ static int __cdecl compareUdpRow(const void *a, const void *b) const MIB_UDPROW *key = a, *value = b; int ret; - ret = key->dwLocalAddr - value->dwLocalAddr; + ret = ntohl(key->dwLocalAddr) - ntohl(value->dwLocalAddr); if (ret == 0) - ret = key->dwLocalPort - value->dwLocalPort; + ret = ntohs(key->dwLocalPort) - ntohs(value->dwLocalPort); return ret; } @@ -1269,8 +1270,9 @@ static BOOL mib2UdpEntryQuery(BYTE bPduType, SnmpVarBind *pVarBind, udpTable->table[tableIndex - 1].dwLocalAddr); if (ret) { + UINT id = ntohs(udpTable->table[tableIndex - 1].dwLocalPort); oid.idLength = 1; - oid.ids = &udpTable->table[tableIndex - 1].dwLocalPort; + oid.ids = &id; ret = SnmpUtilOidAppend(&pVarBind->name, &oid); } }
1
0
0
0
Akihiro Sagawa : quartz: Fix a race in IMediaFilter::Pause().
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: 4642de1d6c9e287a25d1609630335e6d599cd5fc URL:
https://source.winehq.org/git/wine.git/?a=commit;h=4642de1d6c9e287a25d16096…
Author: Akihiro Sagawa <sagawa.aki(a)gmail.com> Date: Fri Dec 10 23:58:15 2021 +0900 quartz: Fix a race in IMediaFilter::Pause(). Before finishing async run, graph->stream_start isn't stable. This will cause graph->current_pos to be out of playback duration. Since graph->current_pos is out of the range, the playback will be stopped. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=52200
Signed-off-by: Akihiro Sagawa <sagawa.aki(a)gmail.com> Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit bbdb6584026393ef1159bd841b61abcad0f1e247) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/quartz/filtergraph.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/quartz/filtergraph.c b/dlls/quartz/filtergraph.c index 20eec80e00c..e6eea7e18ac 100644 --- a/dlls/quartz/filtergraph.c +++ b/dlls/quartz/filtergraph.c @@ -5038,7 +5038,7 @@ static HRESULT WINAPI MediaFilter_Pause(IMediaFilter *iface) if (graph->defaultclock && !graph->refClock) IFilterGraph2_SetDefaultSyncSource(&graph->IFilterGraph2_iface); - if (graph->state == State_Running && graph->refClock) + if (graph->state == State_Running && !graph->needs_async_run && graph->refClock) { REFERENCE_TIME time; IReferenceClock_GetTime(graph->refClock, &time);
1
0
0
0
Eric Pouech : cmd: Don't crash on 'if exist' without parameter.
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: 3bff9ccfa42613f24fe5bbedf1e80624f2570429 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=3bff9ccfa42613f24fe5bbed…
Author: Eric Pouech <eric.pouech(a)gmail.com> Date: Mon Dec 20 10:29:01 2021 +0100 cmd: Don't crash on 'if exist' without parameter. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=51598
Signed-off-by: Eric Pouech <eric.pouech(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit 535da77552deb74198f0fe8fedae3bbab5115ad7) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- programs/cmd/builtins.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/programs/cmd/builtins.c b/programs/cmd/builtins.c index 3f9465320c1..d8e5d061bd4 100644 --- a/programs/cmd/builtins.c +++ b/programs/cmd/builtins.c @@ -2815,8 +2815,9 @@ int evaluate_if_condition(WCHAR *p, WCHAR **command, int *test, int *negate) WCHAR *param = WCMD_parameter(p, 1+(*negate), NULL, FALSE, FALSE); int len = lstrlenW(param); + if (!len) goto syntax_err; /* FindFirstFile does not like a directory path ending in '\', append a '.' */ - if (len && param[len-1] == '\\') lstrcatW(param, L"."); + if (param[len-1] == '\\') lstrcatW(param, L"."); hff = FindFirstFileW(param, &fd); *test = (hff != INVALID_HANDLE_VALUE );
1
0
0
0
Connor McAdams : winex11.drv: Add mutable pixel format awareness.
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: 19de448df69189d6eba1b252818d13202627159c URL:
https://source.winehq.org/git/wine.git/?a=commit;h=19de448df69189d6eba1b252…
Author: Connor McAdams <cmcadams(a)codeweavers.com> Date: Tue Apr 20 13:43:50 2021 -0400 winex11.drv: Add mutable pixel format awareness. Add the ability to check if the pixel format on the current window was previously set by wglSetPixelFormatWine(), and if was, allow the application to change it with a regular wglSetPixelFormat call. Signed-off-by: Connor McAdams <cmcadams(a)codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit 6d04e6c3a9c4c8b1cc2d1ba337c33cc56d1a8ab2) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/winex11.drv/opengl.c | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/dlls/winex11.drv/opengl.c b/dlls/winex11.drv/opengl.c index 4a3ab31273a..3de80eb0c6a 100644 --- a/dlls/winex11.drv/opengl.c +++ b/dlls/winex11.drv/opengl.c @@ -248,6 +248,7 @@ struct gl_drawable SIZE pixmap_size; /* pixmap size for GLXPixmap drawables */ int swap_interval; BOOL refresh_swap_interval; + BOOL mutable_pf; }; enum glx_swap_control_method @@ -1305,7 +1306,8 @@ static GLXContext create_glxcontext(Display *display, struct wgl_context *contex /*********************************************************************** * create_gl_drawable */ -static struct gl_drawable *create_gl_drawable( HWND hwnd, const struct wgl_pixel_format *format, BOOL known_child ) +static struct gl_drawable *create_gl_drawable( HWND hwnd, const struct wgl_pixel_format *format, BOOL known_child, + BOOL mutable_pf ) { struct gl_drawable *gl, *prev; XVisualInfo *visual = format->visual; @@ -1325,6 +1327,7 @@ static struct gl_drawable *create_gl_drawable( HWND hwnd, const struct wgl_pixel gl->refresh_swap_interval = TRUE; gl->format = format; gl->ref = 1; + gl->mutable_pf = mutable_pf; if (!known_child && !GetWindow( hwnd, GW_CHILD ) && GetAncestor( hwnd, GA_PARENT ) == GetDesktopWindow()) /* childless top-level window */ { @@ -1383,13 +1386,13 @@ static struct gl_drawable *create_gl_drawable( HWND hwnd, const struct wgl_pixel /*********************************************************************** * set_win_format */ -static BOOL set_win_format( HWND hwnd, const struct wgl_pixel_format *format ) +static BOOL set_win_format( HWND hwnd, const struct wgl_pixel_format *format, BOOL mutable_pf ) { struct gl_drawable *gl; if (!format->visual) return FALSE; - if (!(gl = create_gl_drawable( hwnd, format, FALSE ))) return FALSE; + if (!(gl = create_gl_drawable( hwnd, format, FALSE, mutable_pf ))) return FALSE; TRACE( "created GL drawable %lx for win %p %s\n", gl->drawable, hwnd, debugstr_fbconfig( format->fbconfig )); @@ -1436,12 +1439,14 @@ static BOOL set_pixel_format(HDC hdc, int format, BOOL allow_change) if ((gl = get_gl_drawable( hwnd, hdc ))) { int prev = pixel_format_index( gl->format ); + BOOL mutable_pf = gl->mutable_pf; release_gl_drawable( gl ); - return prev == format; /* cannot change it if already set */ + if (!mutable_pf) + return prev == format; /* cannot change it if already set */ } } - return set_win_format( hwnd, fmt ); + return set_win_format( hwnd, fmt, allow_change ); } @@ -1460,7 +1465,7 @@ void sync_gl_drawable( HWND hwnd, BOOL known_child ) if (!known_child) break; /* Still a childless top-level window */ /* fall through */ case DC_GL_PIXMAP_WIN: - if (!(new = create_gl_drawable( hwnd, old->format, known_child ))) break; + if (!(new = create_gl_drawable( hwnd, old->format, known_child, old->mutable_pf ))) break; mark_drawable_dirty( old, new ); XFlush( gdi_display ); TRACE( "Recreated GL drawable %lx to replace %lx\n", new->drawable, old->drawable ); @@ -1497,7 +1502,7 @@ void set_gl_drawable_parent( HWND hwnd, HWND parent ) return; } - if ((new = create_gl_drawable( hwnd, old->format, FALSE ))) + if ((new = create_gl_drawable( hwnd, old->format, FALSE, old->mutable_pf ))) { mark_drawable_dirty( old, new ); release_gl_drawable( new );
1
0
0
0
Bernhard Übelacker : hhctrl.ocx: Handle only the number of bytes given in html_fragment_len.
by Alexandre Julliard
12 Apr '22
12 Apr '22
Module: wine Branch: oldstable Commit: 6766fb687ff3fcb344496ad7e81c9bb5f8933117 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6766fb687ff3fcb344496ad7…
Author: Bernhard Übelacker <bernhardu(a)mailbox.org> Date: Tue Jul 6 14:23:13 2021 +0200 hhctrl.ocx: Handle only the number of bytes given in html_fragment_len. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=39699
Signed-off-by: Bernhard Übelacker <bernhardu(a)mailbox.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> (cherry picked from commit e3b28631485a010219928a888fcc543a5bb3c61d) Signed-off-by: Michael Stefaniuc <mstefani(a)winehq.org> --- dlls/hhctrl.ocx/help.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/hhctrl.ocx/help.c b/dlls/hhctrl.ocx/help.c index 06f73358f44..e9957a86e73 100644 --- a/dlls/hhctrl.ocx/help.c +++ b/dlls/hhctrl.ocx/help.c @@ -1898,14 +1898,14 @@ WCHAR *decode_html(const char *html_fragment, int html_fragment_len, UINT code_p while(1) { symbol = 0; - amp = strchr(h, '&'); + amp = memchr(h, '&', html_fragment + html_fragment_len - h); if(!amp) break; len = amp-h; /* Copy the characters prior to the HTML encoded character */ memcpy(&tmp[tmp_len], h, len); tmp_len += len; amp++; /* skip ampersand */ - sem = strchr(amp, ';'); + sem = memchr(amp, ';', html_fragment + html_fragment_len - amp); /* Require a semicolon after the ampersand */ if(!sem) {
1
0
0
0
← Newer
1
...
65
66
67
68
69
70
71
...
103
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
Results per page:
10
25
50
100
200