[grisbi-cvs] grisbi/src gsb_data_partial_balance.c,1.9,1.10

Pierre Biava pbiava at users.sourceforge.net
Sun Nov 15 06:37:14 CET 2009


Update of /cvsroot/grisbi/grisbi/src
In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv21998

Modified Files:
	gsb_data_partial_balance.c 
Log Message:
Fixed a bug in calculation of balance

Index: gsb_data_partial_balance.c
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/gsb_data_partial_balance.c,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -d -r1.9 -r1.10
--- gsb_data_partial_balance.c	24 Oct 2009 19:18:49 -0000	1.9
+++ gsb_data_partial_balance.c	15 Nov 2009 05:37:12 -0000	1.10
@@ -1057,7 +1057,7 @@
         account_currency = gsb_data_account_get_currency ( account_nb );
         tmp_real = gsb_data_account_get_marked_balance ( account_nb );
 
-        if ( partial_balance -> currency != account_currency )
+        if ( tmp_real.mantissa != 0 && partial_balance -> currency != account_currency )
         {
             if ( ( link_number = gsb_data_currency_link_search ( account_currency,
                         partial_balance -> currency ) ) )
@@ -1119,7 +1119,7 @@
         account_currency = gsb_data_account_get_currency ( account_nb );
         tmp_real = gsb_data_account_get_current_balance ( account_nb );
 
-        if ( partial_balance -> currency != account_currency )
+        if ( tmp_real.mantissa != 0 && partial_balance -> currency != account_currency )
         {
             if ( ( link_number = gsb_data_currency_link_search ( account_currency,
                         partial_balance -> currency ) ) )



More information about the cvs mailing list