[client,common] fix incompatible-pointer-types
use a union to cast to expected types.
This commit is contained in:
parent
bcf189b6b3
commit
c22d9844a4
@ -2299,9 +2299,15 @@ BOOL freerdp_client_populate_settings_from_rdp_file(const rdpFile* file, rdpSett
|
||||
if (~file->RedirectLocation)
|
||||
{
|
||||
size_t count = 0;
|
||||
char** str = CommandLineParseCommaSeparatedValuesEx(LOCATION_CHANNEL_NAME, NULL, &count);
|
||||
const BOOL rc = freerdp_client_add_dynamic_channel(settings, count, str);
|
||||
free(str);
|
||||
union
|
||||
{
|
||||
void* pv;
|
||||
char** str;
|
||||
const char** cstr;
|
||||
} cnv;
|
||||
cnv.str = CommandLineParseCommaSeparatedValuesEx(LOCATION_CHANNEL_NAME, NULL, &count);
|
||||
const BOOL rc = freerdp_client_add_dynamic_channel(settings, count, cnv.cstr);
|
||||
free(cnv.pv);
|
||||
if (!rc)
|
||||
return FALSE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user