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

index b05763fbe370de637b62038a10ed8d89cb7977db..81ec66c85f67a63383a3e561f29980bdd051cb3f 100644 (file)
@@ -7125,6 +7125,9 @@ int main_remus(int argc, char **argv)
 
         migrate_do_preamble(send_fd, recv_fd, child, config_data, config_len,
                             rune);
+
+        if (ssh_command[0])
+            free(rune);
     }
 
     /* Point of no return */