Re: [PATCH v2 2/2] ui/vdagent: fix clipboard info memory leak in error path

2021-06-01 Thread Thomas Huth
On 01/06/2021 17.57, Stefan Hajnoczi wrote: If the size of a VD_AGENT_CLIPBOARD_GRAB message is invalid we leak info when returning early. Thanks to Coverity for spotting this: *** CID 1453266: Resource leaks (RESOURCE_LEAK) /qemu/ui/vdagent.c: 465 in vdagent_chr_recv_clipboard() 459

Re: [PATCH v2 2/2] ui/vdagent: fix clipboard info memory leak in error path

2021-06-01 Thread Philippe Mathieu-Daudé
On 6/1/21 5:57 PM, Stefan Hajnoczi wrote: > If the size of a VD_AGENT_CLIPBOARD_GRAB message is invalid we leak info > when returning early. > > Thanks to Coverity for spotting this: > > *** CID 1453266: Resource leaks (RESOURCE_LEAK) > /qemu/ui/vdagent.c: 465 in vdagent_chr_recv_clipboard() >

[PATCH v2 2/2] ui/vdagent: fix clipboard info memory leak in error path

2021-06-01 Thread Stefan Hajnoczi
If the size of a VD_AGENT_CLIPBOARD_GRAB message is invalid we leak info when returning early. Thanks to Coverity for spotting this: *** CID 1453266: Resource leaks (RESOURCE_LEAK) /qemu/ui/vdagent.c: 465 in vdagent_chr_recv_clipboard() 459 info = qemu_clipboard_info_new(>cbpeer,