From ded101119fa301834ae380b745a469171108731b Mon Sep 17 00:00:00 2001 From: akallabeth Date: Mon, 16 Jan 2023 11:04:51 +0100 Subject: [PATCH] [gateway] fix leak in rdg_send_channel_create --- libfreerdp/core/gateway/rdg.c | 1 - 1 file changed, 1 deletion(-) diff --git a/libfreerdp/core/gateway/rdg.c b/libfreerdp/core/gateway/rdg.c index 07bd9b335..9d7493fad 100644 --- a/libfreerdp/core/gateway/rdg.c +++ b/libfreerdp/core/gateway/rdg.c @@ -1142,7 +1142,6 @@ static BOOL rdg_send_channel_create(rdpRdg* rdg) WINPR_ASSERT(rdg); serverName = freerdp_settings_get_string_as_utf16(rdg->settings, FreeRDP_ServerHostname, &serverNameLen); - ConvertUtf8ToWCharAlloc(rdg->settings->ServerHostname, &serverNameLen); if (!serverName || (serverNameLen >= UINT16_MAX / sizeof(WCHAR))) goto fail;