Revision: 7393
Author:   nogu.dev
Date:     Mon Jan  2 02:23:02 2012
Log:      * gtk2/pref/gtk-custom-widgets.c
  - (table_pref_dialog_response_cb): Check if return value of
    g_value_get_string() is NULL.
http://code.google.com/p/uim/source/detail?r=7393

Modified:
 /trunk/gtk2/pref/gtk-custom-widgets.c

=======================================
--- /trunk/gtk2/pref/gtk-custom-widgets.c       Mon Jan  2 02:11:06 2012
+++ /trunk/gtk2/pref/gtk-custom-widgets.c       Mon Jan  2 02:23:02 2012
@@ -1967,8 +1967,10 @@
     custom_table[row][n_columnsForRow] = NULL;
     for (column = 0; column < n_columnsForRow; column++) {
       GValue value = {0, };
+      const gchar *str;
       gtk_tree_model_get_value(model, &iter, column, &value);
-      custom_table[row][column] = strdup(g_value_get_string(&value));
+      str = g_value_get_string(&value);
+      custom_table[row][column] = strdup(str ? str : "");
     }
     gtk_tree_model_iter_next(model, &iter);
   }

Reply via email to