From: Vic Lee Date: Fri, 18 Jan 2019 09:48:06 +0000 (+0800) Subject: rdpsnd/winmm: remove an unnecessary blocking event. X-Git-Tag: 2.0.0~561^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e2df67ab342fb9a0f44b9c01716dbfde7d46ce70;p=platform%2Fupstream%2Ffreerdp.git rdpsnd/winmm: remove an unnecessary blocking event. --- diff --git a/channels/rdpsnd/client/winmm/rdpsnd_winmm.c b/channels/rdpsnd/client/winmm/rdpsnd_winmm.c index c61e02c..d813457 100644 --- a/channels/rdpsnd/client/winmm/rdpsnd_winmm.c +++ b/channels/rdpsnd/client/winmm/rdpsnd_winmm.c @@ -102,14 +102,12 @@ static void CALLBACK rdpsnd_winmm_callback_function(HWAVEOUT hwo, UINT uMsg, DWO case MM_WOM_CLOSE: WLog_DBG(TAG, "MM_WOM_CLOSE"); - SetEvent(winmm->next); break; case MM_WOM_DONE: WLog_DBG(TAG, "MM_WOM_DONE"); lpWaveHdr = (LPWAVEHDR) dwParam1; free(lpWaveHdr); - SetEvent(winmm->next); break; default: @@ -176,7 +174,6 @@ static void rdpsnd_winmm_free(rdpsndDevicePlugin* device) if (winmm) { rdpsnd_winmm_close(device); - CloseHandle(winmm->next); free(winmm); } } @@ -269,7 +266,6 @@ static UINT rdpsnd_winmm_play(rdpsndDevicePlugin* device, const BYTE* data, size return 0; } - WaitForSingleObject(winmm->next, INFINITE); return 10; /* TODO: Get real latencry in [ms] */ } @@ -305,13 +301,6 @@ UINT freerdp_rdpsnd_client_subsystem_entry(PFREERDP_RDPSND_DEVICE_ENTRY_POINTS p winmm->device.Play = rdpsnd_winmm_play; winmm->device.Close = rdpsnd_winmm_close; winmm->device.Free = rdpsnd_winmm_free; - winmm->next = CreateEventA(NULL, FALSE, FALSE, "winmm-play-event"); - - if (!winmm->next) - { - free(winmm); - return CHANNEL_RC_NO_MEMORY; - } args = pEntryPoints->args; rdpsnd_winmm_parse_addin_args((rdpsndDevicePlugin*) winmm, args);