From 747b16aa09709d4e04caec3355173a791c8eee8e Mon Sep 17 00:00:00 2001 From: Darko Koruga Date: Fri, 14 Dec 2001 06:26:36 +0000 Subject: [PATCH] Fix bug #492305 (see description in the changelog). --- ChangeLog.claws | 7 +++++++ configure.in | 2 +- src/compose.c | 16 +++++++++------- 3 files changed, 17 insertions(+), 8 deletions(-) diff --git a/ChangeLog.claws b/ChangeLog.claws index 9a7286d29..a02635e33 100644 --- a/ChangeLog.claws +++ b/ChangeLog.claws @@ -1,3 +1,10 @@ +2001-12-14 [darko] 0.6.5claws84 + + * src/compose.c + fix crash when wrapping long lines if linewrap quotation + is disabled and wrapper encounters a word spanning more + than one line + 2001-12-13 [paul] 0.6.5claws83 * src/compose.c diff --git a/configure.in b/configure.in index a87213d08..4217c5ca2 100644 --- a/configure.in +++ b/configure.in @@ -8,7 +8,7 @@ MINOR_VERSION=6 MICRO_VERSION=5 INTERFACE_AGE=0 BINARY_AGE=0 -EXTRA_VERSION=claws83 +EXTRA_VERSION=claws84 VERSION=$MAJOR_VERSION.$MINOR_VERSION.$MICRO_VERSION$EXTRA_VERSION dnl diff --git a/src/compose.c b/src/compose.c index 0f69a4123..c8ebea65e 100644 --- a/src/compose.c +++ b/src/compose.c @@ -2178,14 +2178,16 @@ static void compose_wrap_line_all(Compose *compose) for (; cur_pos < tlen; cur_pos++) { /* mark position of new line - needed for quotation wrap */ - if (linewrap_quote && is_new_line) { - qlen = gtkut_text_str_compare - (text, cur_pos, tlen, qfmt); + if (is_new_line) { + if (linewrap_quote && is_new_line) { + qlen = gtkut_text_str_compare + (text, cur_pos, tlen, qfmt); + if (qlen) + i_len = get_indent_length(text, cur_pos, tlen); + else + i_len = 0; + } is_new_line = FALSE; - if (qlen) - i_len = get_indent_length(text, cur_pos, tlen); - else - i_len = 0; p_pos = cur_pos; #ifdef WRAP_DEBUG printf("new line i_len=%d qlen=%d p_pos=", i_len, qlen); -- 2.25.1