r22087 - gnucash/trunk/src/import-export - Bug #672161: Fix double-free error when importer dialog is canceled

Christian Stimming cstim at code.gnucash.org
Fri Mar 16 16:26:37 EDT 2012


Author: cstim
Date: 2012-03-16 16:26:36 -0400 (Fri, 16 Mar 2012)
New Revision: 22087
Trac: http://svn.gnucash.org/trac/changeset/22087

Modified:
   gnucash/trunk/src/import-export/import-main-matcher.c
Log:
Bug #672161: Fix double-free error when importer dialog is canceled

Patch by Robert Fewell:

There is an existing problem with the main matcher which can causes the
following errors if you have the relevant account register open:

CRIT <qof> qof_instance_get_editlevel: assertion `QOF_IS_INSTANCE(ptr)' failed

This is caused when you decide to not add all the transactions displayed on the
matcher dialog and then the system trying to delete the temporary transaction
twice. I think this patch comments out the offending lines, if correct I will
provide a patch to remove them.

The error below is only seen when the relevant account register is open and in
the preferences you have double line mode enabled. Not sure how it gets fired,
probably part of the register update process but it is because we do not have a
valid transaction any more.

CRIT <gnc.engine> xaccTransGetVoidReason: assertion `trans' failed

The function concerned is gnc_split_register_get_vnotes_entry and could be
solved by adding the following but not sure if this is a valid fix.

    if(trans == NULL)
        return g_strdup('\0');
    else
        return xaccTransGetVoidReason(trans);



More information about the gnucash-patches mailing list