diff options
Diffstat (limited to 'plugins/email-custom-header')
-rw-r--r-- | plugins/email-custom-header/ChangeLog | 7 | ||||
-rw-r--r-- | plugins/email-custom-header/email-custom-header.c | 13 |
2 files changed, 14 insertions, 6 deletions
diff --git a/plugins/email-custom-header/ChangeLog b/plugins/email-custom-header/ChangeLog index b10181369b..f826eddd86 100644 --- a/plugins/email-custom-header/ChangeLog +++ b/plugins/email-custom-header/ChangeLog @@ -1,3 +1,10 @@ +2009-02-25 Milan Crha <mcrha@redhat.com> + + ** Fix for bug #572399 + + * email-custom-header.c: (header_foreach_check_isempty): + Do not read from invalid iterator after call of row changed. + 2009-02-13 Milan Crha <mcrha@redhat.com> ** Fixes part of bug #564229 diff --git a/plugins/email-custom-header/email-custom-header.c b/plugins/email-custom-header/email-custom-header.c index 233804cd13..994af730b6 100644 --- a/plugins/email-custom-header/email-custom-header.c +++ b/plugins/email-custom-header/email-custom-header.c @@ -684,12 +684,13 @@ header_foreach_check_isempty (GtkTreeModel *model, GtkTreePath *path, GtkTreeIte signal (if we delete the row, then the iter gets corrupted) */ if ((keyword) && !(g_utf8_strlen (g_strstrip (keyword), -1) > 0)) gtk_tree_model_row_changed (model, path, iter); - - gtk_tree_model_get (model, iter, HEADER_VALUE_COLUMN, &value, -1); - /* Check if the keyword is not empty and then emit the row-changed - signal (if we delete the row, then the iter gets corrupted) */ - if ((value) && !(g_utf8_strlen (g_strstrip (value), -1) > 0)) - gtk_tree_model_row_changed (model, path, iter); + else { + gtk_tree_model_get (model, iter, HEADER_VALUE_COLUMN, &value, -1); + /* Check if the keyword is not empty and then emit the row-changed + signal (if we delete the row, then the iter gets corrupted) */ + if ((value) && !(g_utf8_strlen (g_strstrip (value), -1) > 0)) + gtk_tree_model_row_changed (model, path, iter); + } g_free (keyword); g_free (value); |