gnucash maint: Bug 753146 - free(): invalid pointer on duplicate transaction

John Ralls jralls at code.gnucash.org
Sat Aug 1 19:27:12 EDT 2015


Updated	 via  https://github.com/Gnucash/gnucash/commit/18196171 (commit)
	from  https://github.com/Gnucash/gnucash/commit/b41c86da (commit)



commit 18196171ad58eb8a8e4805c9736cb368e6c26f16
Author: John Ralls <jralls at ceridwen.us>
Date:   Sat Aug 1 16:26:53 2015 -0700

    Bug 753146 - free(): invalid pointer on duplicate transaction
    
    when Use Split Action Field for Number is set.

diff --git a/src/register/ledger-core/split-register.c b/src/register/ledger-core/split-register.c
index 90b831a..3531633 100644
--- a/src/register/ledger-core/split-register.c
+++ b/src/register/ledger-core/split-register.c
@@ -494,7 +494,7 @@ gnc_split_register_duplicate_current (SplitRegister *reg)
 
         /* We are on a split in an expanded transaction.
          * Just copy the split and add it to the transaction.
-         * However, if the split-action field is being used as the register 
+         * However, if the split-action field is being used as the register
          * number, and the action field is a number, request a new value or
          * cancel. Need to get next number and update account last num from
          * split account not register account, which may be the same or not */
@@ -566,8 +566,8 @@ gnc_split_register_duplicate_current (SplitRegister *reg)
         int split_index;
         const char *in_num = NULL;
         const char *in_tnum = NULL;
-        char *out_num;
-        char *out_tnum;
+        char *out_num = NULL;
+        char *out_tnum = NULL;
         time64 date;
         gboolean use_autoreadonly = qof_book_uses_autoreadonly(gnc_get_current_book());
 



Summary of changes:
 src/register/ledger-core/split-register.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)



More information about the gnucash-changes mailing list