[grisbi-cvs] grisbi/src import.c, 1.321, 1.322 utils_files.c, 1.51, 1.52

Pierre Biava pbiava at users.sourceforge.net
Sat Feb 6 15:33:39 CET 2010


Update of /cvsroot/grisbi/grisbi/src
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv30974/src

Modified Files:
	import.c utils_files.c 
Log Message:
new modification for the bug 934

Index: import.c
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/import.c,v
retrieving revision 1.321
retrieving revision 1.322
diff -u -d -r1.321 -r1.322
--- import.c	28 Jan 2010 20:25:12 -0000	1.321
+++ import.c	6 Feb 2010 14:33:37 -0000	1.322
@@ -677,7 +677,7 @@
         }
         if ( ( charmap = utils_files_get_ofx_charset ( tmp_str ) ) != NULL )
         {
-            if ( charmap_imported )
+            if ( charmap_imported && strlen ( charmap_imported ) > 0 )
                 g_free ( charmap_imported );
             charmap_imported = charmap;
         }

Index: utils_files.c
===================================================================
RCS file: /cvsroot/grisbi/grisbi/src/utils_files.c,v
retrieving revision 1.51
retrieving revision 1.52
diff -u -d -r1.51 -r1.52
--- utils_files.c	6 Feb 2010 10:02:50 -0000	1.51
+++ utils_files.c	6 Feb 2010 14:33:37 -0000	1.52
@@ -864,12 +864,7 @@
         ptr_tmp = g_strstr_len ( ptr, strlen ( ptr ), "\n" );
         if ( ptr_tmp )
         {
-            gchar *ptr_r;
-
             string = g_strndup ( ptr, ( ( ptr_tmp ) - ptr ) );
-            if ( ( ptr_r = g_strrstr ( string, "\r" ) ) )
-                ptr_r[0] = '\0';
-
             if ( ( tmp_str = g_strrstr ( string, "CHARSET:" ) ) )
             {
                 do
@@ -882,7 +877,6 @@
                     i++;
                 } while ( all_charset_array[i] );
             }
-
             g_free ( string );
             ptr = ptr_tmp + 1;
         }



More information about the cvs mailing list