aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomas Popela <tpopela@redhat.com>2014-06-10 15:20:09 +0800
committerTomas Popela <tpopela@redhat.com>2014-06-10 15:20:09 +0800
commit483a0a28e5a0818094e9b3409b7aa156e56175ca (patch)
treedf76e5de21e8788b092efbde63b14724d34e48ea
parent8650fb139a9143f04615de74ff569bce3e0c4ce3 (diff)
downloadgsoc2013-evolution-483a0a28e5a0818094e9b3409b7aa156e56175ca.tar
gsoc2013-evolution-483a0a28e5a0818094e9b3409b7aa156e56175ca.tar.gz
gsoc2013-evolution-483a0a28e5a0818094e9b3409b7aa156e56175ca.tar.bz2
gsoc2013-evolution-483a0a28e5a0818094e9b3409b7aa156e56175ca.tar.lz
gsoc2013-evolution-483a0a28e5a0818094e9b3409b7aa156e56175ca.tar.xz
gsoc2013-evolution-483a0a28e5a0818094e9b3409b7aa156e56175ca.tar.zst
gsoc2013-evolution-483a0a28e5a0818094e9b3409b7aa156e56175ca.zip
Bug 731416 - [webkit-composer] Busy-loop when replying to an email
Don't try to wrap words that are longer than defined word wrap length, otherwise we will end in busy loop.
-rw-r--r--e-util/e-html-editor-selection.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/e-util/e-html-editor-selection.c b/e-util/e-html-editor-selection.c
index c109063f41..131fc86ead 100644
--- a/e-util/e-html-editor-selection.c
+++ b/e-util/e-html-editor-selection.c
@@ -4566,7 +4566,10 @@ find_where_to_break_line (WebKitDOMNode *node,
if (g_unichar_isspace (g_utf8_get_char (position))) {
ret_val = max_len + 1;
} else {
- if (last_space < max_len) {
+ if (last_space == 0) {
+ /* If word is longer than word_wrap_length, we cannot wrap it */
+ ret_val = length;
+ } else if (last_space < max_len) {
ret_val = last_space;
} else {
if (length > word_wrap_length)