[evolution] EHTMLEditorView - Crash in selection_is_in_table function
- From: Tomas Popela <tpopela src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution] EHTMLEditorView - Crash in selection_is_in_table function
- Date: Mon, 9 Mar 2015 10:23:42 +0000 (UTC)
commit da074351455c7f5d1db3370642ddc178f6e5e000
Author: Tomas Popela <tpopela redhat com>
Date: Mon Mar 9 11:21:22 2015 +0100
EHTMLEditorView - Crash in selection_is_in_table function
Check if the passed variable is not NULL before working with it.
e-util/e-html-editor-view.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/e-util/e-html-editor-view.c b/e-util/e-html-editor-view.c
index e05bbf6..2513e7e 100644
--- a/e-util/e-html-editor-view.c
+++ b/e-util/e-html-editor-view.c
@@ -3157,11 +3157,15 @@ selection_is_in_table (WebKitDOMDocument *document,
}
}
if (WEBKIT_DOM_IS_HTML_TABLE_ELEMENT (parent)) {
- *table_node = parent;
+ if (table_node != NULL)
+ *table_node = parent;
}
parent = webkit_dom_node_get_parent_node (parent);
}
+ if (table_node == NULL)
+ return FALSE;
+
return *table_node != NULL;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]