From: Richard Jones Date: Thu, 16 Apr 2009 16:38:27 +0000 (+0100) Subject: Missing free() on return path (thanks: Steve Grubb). X-Git-Tag: 1.0.0~3 X-Git-Url: http://git.annexia.org/?a=commitdiff_plain;h=1e60354dc8fb306fa139ae744a596f4f5bcbd9a7;p=libguestfs.git Missing free() on return path (thanks: Steve Grubb). --- diff --git a/daemon/stubs.c b/daemon/stubs.c index 2711000..dfadb83 100644 --- a/daemon/stubs.c +++ b/daemon/stubs.c @@ -2011,6 +2011,7 @@ parse_command_line_pvs (void) reply_with_error ("%s", err); free (out); free (err); + free (ret); return NULL; } @@ -2350,6 +2351,7 @@ parse_command_line_vgs (void) reply_with_error ("%s", err); free (out); free (err); + free (ret); return NULL; } @@ -2659,6 +2661,7 @@ parse_command_line_lvs (void) reply_with_error ("%s", err); free (out); free (err); + free (ret); return NULL; } diff --git a/src/generator.ml b/src/generator.ml index bd8afb7..41fc0c8 100755 --- a/src/generator.ml +++ b/src/generator.ml @@ -2394,6 +2394,7 @@ and generate_daemon_actions () = pr " reply_with_error (\"%%s\", err);\n"; pr " free (out);\n"; pr " free (err);\n"; + pr " free (ret);\n"; pr " return NULL;\n"; pr " }\n"; pr "\n";