Fixed cleanup of resources, only in error case now.

This commit is contained in:
Armin Novak 2015-06-24 14:59:59 +02:00
parent c78b6f38ab
commit 80ba4643dc
1 changed files with 4 additions and 3 deletions

View File

@ -124,7 +124,6 @@ int freerdp_assistance_parse_address_list(rdpAssistanceFile* file, char* list)
int count;
int length;
char** tokens;
int ret = -1;
count = 1;
str = _strdup(list);
@ -222,7 +221,9 @@ int freerdp_assistance_parse_address_list(rdpAssistanceFile* file, char* list)
break;
}
ret = 1;
free(tokens);
free(str);
return 1;
out:
if (file->MachineAddresses)
{
@ -238,7 +239,7 @@ out:
free(tokens);
free(str);
return ret;
return -1;
}
int freerdp_assistance_parse_connection_string1(rdpAssistanceFile* file)