[Xfce4-commits] <terminal:master> Protect against NULL border values (bug #7120).
Nick Schermer
noreply at xfce.org
Sun Jan 30 14:36:05 CET 2011
Updating branch refs/heads/master
to bfe5fd39bf96c0d39c0a85cd2ccc171253b1e54a (commit)
from 715a78dc3cc93ab3a49d9c59a88ca34a88824206 (commit)
commit bfe5fd39bf96c0d39c0a85cd2ccc171253b1e54a
Author: Nick Schermer <nick at xfce.org>
Date: Sun Jan 30 14:33:50 2011 +0100
Protect against NULL border values (bug #7120).
terminal/terminal-screen.c | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/terminal/terminal-screen.c b/terminal/terminal-screen.c
index 7298425..42801c4 100644
--- a/terminal/terminal-screen.c
+++ b/terminal/terminal-screen.c
@@ -1497,9 +1497,16 @@ terminal_screen_set_window_geometry_hints (TerminalScreen *screen,
#if VTE_CHECK_VERSION (0, 24, 0)
gtk_widget_style_get (GTK_WIDGET (screen->terminal), "inner-border", &border, NULL);
- xpad = border->left + border->right;
- ypad = border->top + border->bottom;
- gtk_border_free (border);
+ if (border != NULL)
+ {
+ xpad = border->left + border->right;
+ ypad = border->top + border->bottom;
+ gtk_border_free (border);
+ }
+ else
+ {
+ xpad = ypad = 0;
+ }
#else
vte_terminal_get_padding (VTE_TERMINAL (screen->terminal), &xpad, &ypad);
#endif
More information about the Xfce4-commits
mailing list