summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBehdad Esfahbod <behdad@gnome.org>2006-06-07 16:46:39 +0000
committerBehdad Esfahbod <behdad@src.gnome.org>2006-06-07 16:46:39 +0000
commit14eda4d86401762c88040af70c4259a09b6c4614 (patch)
tree3bad58fef80deccd47bb4f4f870c3f931920ac18
parent24536e9b33000952996361aa6f27bdec540fd274 (diff)
downloadvte-14eda4d86401762c88040af70c4259a09b6c4614.tar.gz
Bug 339529 – gnome-terminal (vte) crashes when detatched window is
2006-06-07 Behdad Esfahbod <behdad@gnome.org> Bug 339529 – gnome-terminal (vte) crashes when detatched window is closed * src/vte.c (vte_invalidate_region): Bail out if terminal->window is NULL.
-rw-r--r--ChangeLog8
-rw-r--r--src/vte.c5
2 files changed, 12 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 2eb67c78..bfe3fbf4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2006-06-07 Behdad Esfahbod <behdad@gnome.org>
+
+ Bug 339529 – gnome-terminal (vte) crashes when detatched window is
+ closed
+
+ * src/vte.c (vte_invalidate_region): Bail out if terminal->window is
+ NULL.
+
2006-05-27 Behdad Esfahbod <behdad@gnome.org>
Bug 342549 – uninitialized var (coverity)
diff --git a/src/vte.c b/src/vte.c
index 60e3315d..d5af502f 100644
--- a/src/vte.c
+++ b/src/vte.c
@@ -198,7 +198,10 @@ _vte_terminal_set_default_attributes(VteTerminal *terminal)
static gboolean
vte_invalidate_region(VteTerminal *terminal)
{
- if (!GTK_WIDGET_REALIZED(terminal))
+ if (G_UNLIKELY (!GTK_WIDGET_REALIZED(terminal)))
+ return FALSE;
+
+ if (G_UNLIKELY (GTK_WIDGET(terminal)->window == NULL))
return FALSE;
if (!terminal->pvt->update_region)