]> xenbits.xensource.com Git - xen.git/commitdiff
libxl: fix leak of corename in handle_domain_death
authorMatthew Daley <mattjd@gmail.com>
Wed, 18 Sep 2013 03:37:42 +0000 (15:37 +1200)
committerIan Campbell <ian.campbell@citrix.com>
Wed, 25 Sep 2013 11:45:39 +0000 (12:45 +0100)
Coverity-ID: 1087192
Signed-off-by: Matthew Daley <mattjd@gmail.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
tools/libxl/xl_cmdimpl.c

index a609b98b0f95ace584955d423dfb442c1e1409e4..211bdea01a5ca280c9f74f70cb46f60dfa83a138 100644 (file)
@@ -1621,6 +1621,7 @@ static int handle_domain_death(uint32_t *r_domid,
             LOG("dumping core to %s", corefile);
             rc=libxl_domain_core_dump(ctx, *r_domid, corefile, NULL);
             if (rc) LOG("core dump failed (rc=%d).", rc);
+            free(corefile);
         }
         /* No point crying over spilled milk, continue on failure. */