mirror of
https://github.com/morgan9e/FreeRDP
synced 2026-04-14 00:14:11 +09:00
[client,common] fix memory leak in rdpParser
When duplicate lines are found in a RDP file the old entry was not freed up.
This commit is contained in:
@@ -716,6 +716,9 @@ static BOOL freerdp_client_rdp_file_set_string(rdpFile* file, const char* name,
|
||||
|
||||
if (targetValue)
|
||||
{
|
||||
if ((uintptr_t)(*targetValue) != UINTPTR_MAX)
|
||||
free(*targetValue);
|
||||
|
||||
*targetValue = _strdup(value);
|
||||
if (!(*targetValue))
|
||||
return FALSE;
|
||||
|
||||
Reference in New Issue
Block a user