← Back to team overview

ayatana-commits team mailing list archive

[Merge] lp:~mterry/indicator-datetime/727089 into lp:indicator-datetime

 

Michael Terry has proposed merging lp:~mterry/indicator-datetime/727089 into lp:indicator-datetime.

Requested reviews:
  Indicator Applet Developers (indicator-applet-developers)
Related bugs:
  Bug #727089 in Indicator Date and Time: "indicator-datetime-preferences crashed with SIGSEGV in g_utf8_normalize()"
  https://bugs.launchpad.net/indicator-datetime/+bug/727089

For more details, see:
https://code.launchpad.net/~mterry/indicator-datetime/727089/+merge/55409

Guard entry-specific calls by checking if we even have an entry now.  Works around crash in gtk if they are called without an entry.
-- 
https://code.launchpad.net/~mterry/indicator-datetime/727089/+merge/55409
Your team ayatana-commits is subscribed to branch lp:indicator-datetime.
=== modified file 'src/timezone-completion.c'
--- src/timezone-completion.c	2011-03-29 16:18:57 +0000
+++ src/timezone-completion.c	2011-03-29 19:20:57 +0000
@@ -79,12 +79,15 @@
     gtk_entry_completion_set_match_func (GTK_ENTRY_COMPLETION (completion), match_func, NULL, NULL);
 
   gtk_entry_completion_set_model (GTK_ENTRY_COMPLETION (completion), model);
-  gtk_entry_completion_complete (GTK_ENTRY_COMPLETION (completion));
-
-  /* By this time, the changed signal has come and gone.  We didn't give a
-     model to use, so no popup appeared for user.  Poke the entry again to show
-     popup in 300ms. */
-  g_signal_emit_by_name (priv->entry, "changed");
+
+  if (priv->entry != NULL) {
+    gtk_entry_completion_complete (GTK_ENTRY_COMPLETION (completion));
+
+    /* By this time, the changed signal has come and gone.  We didn't give a
+       model to use, so no popup appeared for user.  Poke the entry again to show
+       popup in 300ms. */
+    g_signal_emit_by_name (priv->entry, "changed");
+  }
 }
 
 static gint


Follow ups