mirror of
https://github.com/Gnucash/gnucash.git
synced 2025-02-25 18:55:30 -06:00
Free template root accounts on book end
The template root should be unset so that it's destroyed when the book is ending. This is required to free all the template accounts and referenced strings. The scheduled transactions themselves need to be freed first so reverse the order that SXRegister and gnc_sxtt_register are called in cashobjects_register: The list resulting from that function is traversed from the bottom up.
This commit is contained in:
parent
0061e21c4f
commit
4a8acf3fb2
@ -127,7 +127,7 @@ sxtg_book_begin (QofBook *book)
|
||||
static void
|
||||
sxtg_book_end (QofBook *book)
|
||||
{
|
||||
// gnc_book_set_template_root (book, NULL);
|
||||
gnc_book_set_template_root (book, NULL);
|
||||
}
|
||||
|
||||
static gboolean
|
||||
|
@ -73,8 +73,8 @@ cashobjects_register(void)
|
||||
g_return_val_if_fail(xaccAccountRegister(), FALSE);
|
||||
g_return_val_if_fail ( xaccTransRegister(), FALSE);
|
||||
g_return_val_if_fail ( xaccSplitRegister(), FALSE);
|
||||
g_return_val_if_fail ( SXRegister (), FALSE);
|
||||
g_return_val_if_fail ( gnc_sxtt_register(), FALSE);
|
||||
g_return_val_if_fail ( SXRegister (), FALSE);
|
||||
g_return_val_if_fail(gnc_pricedb_register(), FALSE);
|
||||
g_return_val_if_fail (gnc_budget_register(), FALSE);
|
||||
g_return_val_if_fail ( gnc_lot_register (), FALSE);
|
||||
|
Loading…
Reference in New Issue
Block a user