r14898 - gnucash/trunk - Free a list in import-account-matcher.c.

Andreas Köhler andi5 at cvs.gnucash.org
Tue Sep 26 18:08:54 EDT 2006


Author: andi5
Date: 2006-09-26 18:08:52 -0400 (Tue, 26 Sep 2006)
New Revision: 14898
Trac: http://svn.gnucash.org/trac/changeset/14898

Modified:
   gnucash/trunk/
   gnucash/trunk/src/import-export/import-account-matcher.c
Log:
Free a list in import-account-matcher.c.



Property changes on: gnucash/trunk
___________________________________________________________________
Name: svk:merge
   - 3889ce50-311e-0410-a464-f059747ec5d1:/local/gnucash/trunk:643
d2ab10a8-8a95-4986-baff-8d511d9f15b2:/local/gnucash/trunk:13351
   + 3889ce50-311e-0410-a464-f059747ec5d1:/local/gnucash/trunk:646
d2ab10a8-8a95-4986-baff-8d511d9f15b2:/local/gnucash/trunk:13351

Modified: gnucash/trunk/src/import-export/import-account-matcher.c
===================================================================
--- gnucash/trunk/src/import-export/import-account-matcher.c	2006-09-26 22:08:34 UTC (rev 14897)
+++ gnucash/trunk/src/import-export/import-account-matcher.c	2006-09-26 22:08:52 UTC (rev 14898)
@@ -98,17 +98,18 @@
   Account *selected_account, *new_account;
   GList * valid_types = NULL;
   /*DEBUG("Begin");  */
-  
+
   if(picker->new_account_default_type!=ACCT_TYPE_NONE)
     {
       /*Yes, this is weird, but we really DO want to pass the value instead of the pointer...*/
-     valid_types = g_list_prepend(valid_types, (gpointer)picker->new_account_default_type);
+      valid_types = g_list_prepend(valid_types, GINT_TO_POINTER(picker->new_account_default_type));
     }
   selected_account = gnc_tree_view_account_get_selected_account(picker->account_tree);
   new_account = gnc_ui_new_accounts_from_name_with_defaults ( picker->account_human_description,
 							      valid_types,
 							      picker->new_account_default_commodity,
 							      selected_account);
+  g_list_free(valid_types);
   gnc_tree_view_account_set_selected_account(picker->account_tree, new_account);
 }
 



More information about the gnucash-changes mailing list