diff options
author | Marc-André Lureau <marcandre.lureau@redhat.com> | 2015-08-27 01:34:56 +0200 |
---|---|---|
committer | Michael Roth <mdroth@linux.vnet.ibm.com> | 2015-09-01 13:16:22 -0500 |
commit | d4c8a5d49e514bfeac2040ee5371b4e6a7d8d561 (patch) | |
tree | 625c00948a8ba4b4323c603b20f9cb074c84c5fd /qga | |
parent | e3d3103975112a1ab8a0129a4be1cfe3314bce8b (diff) | |
download | qemu-d4c8a5d49e514bfeac2040ee5371b4e6a7d8d561.zip |
qga: free a bit more
Now that main() has a single exit point, we can free a few
more allocations.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Denis V. Lunev <den@openvz.org>
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Diffstat (limited to 'qga')
-rw-r--r-- | qga/main.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/qga/main.c b/qga/main.c index b5859bb7cb..fc0769657c 100644 --- a/qga/main.c +++ b/qga/main.c @@ -82,7 +82,7 @@ struct GAState { bool delimit_response; bool frozen; GList *blacklist; - const char *state_filepath_isfrozen; + char *state_filepath_isfrozen; struct { const char *log_filepath; const char *pid_filepath; @@ -90,7 +90,7 @@ struct GAState { #ifdef CONFIG_FSFREEZE const char *fsfreeze_hook; #endif - const gchar *pstate_filepath; + gchar *pstate_filepath; GAPersistentState pstate; }; @@ -1254,6 +1254,8 @@ end: ga_channel_free(s->channel); } g_list_foreach(config->blacklist, free_blacklist_entry, NULL); + g_free(s->pstate_filepath); + g_free(s->state_filepath_isfrozen); if (config->daemonize) { unlink(config->pid_filepath); |