r22015 - gnucash/branches/2.4/src/gnome - [22011] Fix a GtkWarning in the Account Hierarchy Druid which occurs

Geert Janssens gjanssens at code.gnucash.org
Sun Feb 12 15:48:02 EST 2012


Author: gjanssens
Date: 2012-02-12 15:48:02 -0500 (Sun, 12 Feb 2012)
New Revision: 22015
Trac: http://svn.gnucash.org/trac/changeset/22015

Modified:
   gnucash/branches/2.4/src/gnome/druid-hierarchy.c
Log:
[22011] Fix a GtkWarning in the Account Hierarchy Druid which occurs
if the Example Account file doesn't contain a long description.

Modified: gnucash/branches/2.4/src/gnome/druid-hierarchy.c
===================================================================
--- gnucash/branches/2.4/src/gnome/druid-hierarchy.c	2012-02-12 20:46:19 UTC (rev 22014)
+++ gnucash/branches/2.4/src/gnome/druid-hierarchy.c	2012-02-12 20:48:02 UTC (rev 22015)
@@ -496,7 +496,9 @@
         g_free(text2);
         g_free(text);
         buffer = gtk_text_view_get_buffer(data->category_description);
-        gtk_text_buffer_set_text(buffer, gea->long_description, -1);
+        gtk_text_buffer_set_text(buffer, gea->long_description ?
+                                         gea->long_description :
+                                         "" , -1);
 
         tree_view = gnc_tree_view_account_new_with_root (gea->root, FALSE);
         /* Override the normal fixed (user settable) sizing */



More information about the gnucash-changes mailing list