mirror of
https://github.com/morgan9e/FreeRDP
synced 2026-04-14 16:34:18 +09:00
[winpr,collections] fix PubSub_OnEvent return checks
* proper return checks on use * fix return on invalid input arguments * fix return on no event registered
This commit is contained in:
@@ -592,12 +592,14 @@ static UINT rdpgfx_recv_reset_graphics_pdu(GENERIC_CHANNEL_CALLBACK* callback, w
|
||||
error);
|
||||
}
|
||||
|
||||
free(pdu.monitorDefArray);
|
||||
|
||||
/* some listeners may be interested (namely the display channel) */
|
||||
EventArgsInit(&graphicsReset, "libfreerdp");
|
||||
graphicsReset.width = pdu.width;
|
||||
graphicsReset.height = pdu.height;
|
||||
PubSub_OnGraphicsReset(gfx->rdpcontext->pubSub, gfx->rdpcontext, &graphicsReset);
|
||||
free(pdu.monitorDefArray);
|
||||
if (PubSub_OnGraphicsReset(gfx->rdpcontext->pubSub, gfx->rdpcontext, &graphicsReset) < 0)
|
||||
return ERROR_INTERNAL_ERROR;
|
||||
return error;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user