[libegg] EggSpreadTableDnd: Improve warnings.
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libegg] EggSpreadTableDnd: Improve warnings.
- Date: Thu, 1 Sep 2011 10:09:01 +0000 (UTC)
commit f52321b9b9fbccb0eb5d3141a7f2894d52883b0f
Author: Murray Cumming <murrayc murrayc com>
Date: Thu Sep 1 12:08:55 2011 +0200
EggSpreadTableDnd: Improve warnings.
libegg/spreadtable/eggspreadtablednd.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/libegg/spreadtable/eggspreadtablednd.c b/libegg/spreadtable/eggspreadtablednd.c
index 26e0a68..c7f7e38 100644
--- a/libegg/spreadtable/eggspreadtablednd.c
+++ b/libegg/spreadtable/eggspreadtablednd.c
@@ -1270,10 +1270,15 @@ egg_spread_table_dnd_remove_child (EggSpreadTableDnd *table,
g_return_if_fail (GTK_IS_WIDGET (child));
event_box = gtk_widget_get_parent (child);
+ if (!event_box)
+ {
+ g_message ("Bad hierarchy encountered in %s. The child had no parent.", G_STRFUNC);
+ return;
+ }
if (GPOINTER_TO_INT (g_object_get_qdata (G_OBJECT (event_box), dnd_table_child_quark)) == FALSE)
{
- g_message ("Bad hierarchy encountered in egg_spread_table_dnd_remove_child().");
+ g_message ("Bad hierarchy encountered in %s.", G_STRFUNC);
return;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]