From aa36058c1d8723feac8e1e7e6acea6d038853cb9 Mon Sep 17 00:00:00 2001 From: Daniel Collins Date: Tue, 8 Nov 2011 22:01:32 +0000 Subject: [PATCH] Updated changelog and added some notes to service provider. --- changes.txt | 8 ++++++++ src/directplay.c | 17 +++++++++-------- 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/changes.txt b/changes.txt index 25334f3..6d4c77c 100644 --- a/changes.txt +++ b/changes.txt @@ -1,3 +1,11 @@ +Version 0.3.2: + Cleanup: Cleaned up Send/SendEx functions in DirectPlay service provider. + + Bugfix: Added workaround for Hamachi bug. + + Bugfix: Correctly return single interfaces from get_interfaces when some + are disabled in ipxconfig. + Version 0.3.1: Bugfix: Fixed deadlock in DirectPlay service provider. diff --git a/src/directplay.c b/src/directplay.c index 11064e4..815ebcc 100644 --- a/src/directplay.c +++ b/src/directplay.c @@ -235,6 +235,11 @@ static HRESULT WINAPI IPX_Send(LPDPSP_SENDDATA data) { return DP_OK; } +/* This function is completely untested. It ignores the DPSEND_ASYNC flag and + * part of the interface has been guessed. Attempts at testing have failed as + * the DirectPlay builds on my test machine (XP _AND_ 7) call SP_Send, even + * when SP_SendEx is implemented and DPSEND_ASYNC is used. +*/ static HRESULT WINAPI IPX_SendEx(LPDPSP_SENDEXDATA data) { CALL("SP_SendEx"); @@ -248,11 +253,6 @@ static HRESULT WINAPI IPX_SendEx(LPDPSP_SENDEXDATA data) { return DPERR_UNSUPPORTED; } - if(data->dwFlags & DPSEND_ASYNC) { - log_printf("SendEx called with DPSEND_ASYNC flag, not implemented"); - return DPERR_UNSUPPORTED; - } - /* NOTE: The buffer arrangement is entirely guessed and currently untested. * TODO: TEST! */ @@ -276,8 +276,6 @@ static HRESULT WINAPI IPX_SendEx(LPDPSP_SENDEXDATA data) { return DP_OK; } - /* TODO: Support DPSEND_ASYNC */ - struct sp_data *sp_data = get_sp_data(data->lpISP); if(sendto(sp_data->sock, buf, off, 0, (struct sockaddr*)&addr, sizeof(addr)) == -1) { @@ -348,9 +346,12 @@ static HRESULT WINAPI IPX_GetCaps(LPDPSP_GETCAPSDATA data) { /* Most values are incorrect/inaccurate, copied from the MS implementation * for compatibility. + * + * No async support is implemented at this time, DirectPlay itself seems + * to handle it. */ - data->lpCaps->dwFlags = 0; + data->lpCaps->dwFlags = DPCAPS_ASYNCSUPPORTED; data->lpCaps->dwMaxBufferSize = 1024; data->lpCaps->dwMaxQueueSize = 0; data->lpCaps->dwMaxPlayers = 65536;