On 2/27/26 13:39, Leander Kohler wrote: > virNetClientMarkClose() may cache the current error in client->error via > virSaveLastError() when a client is marked for close. > > That error is normally released in virNetClientCloseLocked(), but some > teardown paths can dispose the client object without reaching that > cleanup. > In that case, client->error remains allocated and ASan reports a leak. > > Free client->error in virNetClientDispose() as a final cleanup fallback. > > This was observed during virtchd shutdown in test_disk_is_locked, with > the leak originating from: > virDomainInterfaceDeleteDevice() -> remoteConnectClose() -> > virNetClientMarkClose() -> virSaveLastError() > > On-behalf-of: SAP [email protected] > Signed-off-by: Leander Kohler <[email protected]> > --- > src/rpc/virnetclient.c | 2 ++ > 1 file changed, 2 insertions(+) >
Reviewed-by: Michal Privoznik <[email protected]> and merged. Congratulations on your first libvirt contribution! Michal
