gnucash stable: [gnc-plugin-page-account-tree.cpp] some memory leaks plugged
Christopher Lam
clam at code.gnucash.org
Tue Mar 4 17:43:37 EST 2025
Updated via https://github.com/Gnucash/gnucash/commit/12321ac7 (commit)
from https://github.com/Gnucash/gnucash/commit/bc7fafd4 (commit)
commit 12321ac7e8b02480d66f42bff239f80d09c6774c
Author: Christopher Lam <christopher.lck at gmail.com>
Date: Wed Mar 5 06:30:38 2025 +0800
[gnc-plugin-page-account-tree.cpp] some memory leaks plugged
diff --git a/gnucash/gnome/gnc-plugin-page-account-tree.cpp b/gnucash/gnome/gnc-plugin-page-account-tree.cpp
index 515173aa36..659c2345d4 100644
--- a/gnucash/gnome/gnc-plugin-page-account-tree.cpp
+++ b/gnucash/gnome/gnc-plugin-page-account-tree.cpp
@@ -1314,6 +1314,7 @@ commodity_mismatch_dialog (const Account* account, GtkWindow* parent)
response = gtk_dialog_run (GTK_DIALOG (error_dialog));
gtk_widget_destroy (error_dialog);
g_free (message);
+ g_free (account_name);
return response;
}
@@ -1529,6 +1530,7 @@ gnc_plugin_page_account_tree_cmd_delete_account (GSimpleAction *simple,
g_list_free(list);
return;
}
+ g_list_free (list);
window = gnc_plugin_page_get_window(GNC_PLUGIN_PAGE(page));
acct_name = gnc_account_get_full_name(account);
@@ -1542,6 +1544,7 @@ gnc_plugin_page_account_tree_cmd_delete_account (GSimpleAction *simple,
g_free(acct_name);
return;
}
+ g_free (acct_name);
// If no transaction or children just delete it.
if (xaccAccountGetSplits (account).empty() && gnc_account_n_children (account) == 0)
Summary of changes:
gnucash/gnome/gnc-plugin-page-account-tree.cpp | 3 +++
1 file changed, 3 insertions(+)
More information about the gnucash-changes
mailing list