Fixed use after free.

This commit is contained in:
Armin Novak 2016-10-06 13:04:06 +02:00
parent cba67668ca
commit 9d0f7534e3
1 changed files with 2 additions and 1 deletions

View File

@ -1447,10 +1447,11 @@ static VOID VCAPITYPE rdpsnd_virtual_channel_init_event(LPVOID pInitHandle,
"rdpsnd_virtual_channel_event_disconnected failed with error %lu!", error);
rdpsnd_virtual_channel_event_terminated(plugin);
plugin = NULL;
break;
}
if (error && plugin->rdpcontext)
if (error && plugin && plugin->rdpcontext)
setChannelError(plugin->rdpcontext, error,
"rdpsnd_virtual_channel_init_event reported an error");
}