r22079 - gnucash/trunk/src/engine - Use correct list iterator instead of list pointer.

Geert Janssens gjanssens at code.gnucash.org
Tue Mar 13 17:22:58 EDT 2012


Author: gjanssens
Date: 2012-03-13 17:22:58 -0400 (Tue, 13 Mar 2012)
New Revision: 22079
Trac: http://svn.gnucash.org/trac/changeset/22079

Modified:
   gnucash/trunk/src/engine/gncInvoice.c
Log:
Use correct list iterator instead of list pointer.
(Bug pointed out by Christian Stimming)

Modified: gnucash/trunk/src/engine/gncInvoice.c
===================================================================
--- gnucash/trunk/src/engine/gncInvoice.c	2012-03-13 13:18:51 UTC (rev 22078)
+++ gnucash/trunk/src/engine/gncInvoice.c	2012-03-13 21:22:58 UTC (rev 22079)
@@ -1530,7 +1530,7 @@
      * were copied to a new lot, to which later an invoice was added again and so on.
      * These over-payments were handled with automatic payment forward transactions.
      * You could consider these transactions to be links between lots as well, but
-     * to avoid some unexpected behavior, these are will not be altered here.
+     * to avoid some unexpected behavior, these will not be altered here.
      */
     lot_split_list = gnc_lot_get_split_list (lot);
     for (lot_split_iter = lot_split_list; lot_split_iter; lot_split_iter = lot_split_iter->next)
@@ -1550,7 +1550,7 @@
         other_split_list = xaccTransGetSplitList (other_txn);
         for (list_iter = other_split_list; list_iter; list_iter = list_iter->next)
         {
-            Split *other_split = other_split_list->data;
+            Split *other_split = list_iter->data;
             GNCLot *other_lot = xaccSplitGetLot (other_split);
 
             /* Omit the lot we are about to delete */



More information about the gnucash-changes mailing list