winepath: Free wine_get_(dos|unix)_file_name memory with HeapFree.

This commit is contained in:
Rémi Bernon 2022-11-25 16:11:59 +01:00 committed by Alexandre Julliard
parent a49838f24e
commit 1c30f7803c

View file

@ -215,7 +215,7 @@ int __cdecl wmain(int argc, WCHAR *argv[])
{
printf("%s%c", unix_name, separator);
}
free( unix_name );
HeapFree( GetProcessHeap(), 0, unix_name );
break;
}
@ -262,7 +262,7 @@ int __cdecl wmain(int argc, WCHAR *argv[])
{
WideCharToMultiByte(CP_UNIXCP, 0, windows_name, -1, path, MAX_PATH, NULL, NULL);
printf("%s%c", path, separator);
free( windows_name );
HeapFree( GetProcessHeap(), 0, windows_name );
}
else printf("%c", separator);
free( unix_name );