[evolution/gnome-3-28] Crash when making links clickable in composer
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/gnome-3-28] Crash when making links clickable in composer
- Date: Fri, 18 May 2018 06:05:56 +0000 (UTC)
commit 9895adcff58c879b2fecf33ec0a7182da8e6dc68
Author: Milan Crha <mcrha redhat com>
Date: Fri May 18 08:06:38 2018 +0200
Crash when making links clickable in composer
.../web-extension/e-editor-dom-functions.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/modules/webkit-editor/web-extension/e-editor-dom-functions.c
b/src/modules/webkit-editor/web-extension/e-editor-dom-functions.c
index a835850..343b1c1 100644
--- a/src/modules/webkit-editor/web-extension/e-editor-dom-functions.c
+++ b/src/modules/webkit-editor/web-extension/e-editor-dom-functions.c
@@ -1594,11 +1594,13 @@ e_editor_dom_check_magic_links (EEditorPage *editor_page,
webkit_dom_text_split_text (
WEBKIT_DOM_TEXT (node), url_start, NULL);
url_text_node = webkit_dom_node_get_next_sibling (node);
- url_text = webkit_dom_character_data_get_data (
- WEBKIT_DOM_CHARACTER_DATA (url_text_node));
+ if (url_text_node)
+ url_text = webkit_dom_character_data_get_data (WEBKIT_DOM_CHARACTER_DATA
(url_text_node));
+ else
+ url_text = NULL;
/* Sanity check */
- if (strrchr (url_text, ' '))
+ if (!url_text || !*url_text || strrchr (url_text, ' '))
goto skip;
if (g_str_has_prefix (url_text, "www."))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]