fix bug 3801, 'Broken auto wrapping'
authorPaul <paul@claws-mail.org>
Sun, 2 Apr 2017 11:24:20 +0000 (12:24 +0100)
committerPaul <paul@claws-mail.org>
Sun, 2 Apr 2017 11:24:20 +0000 (12:24 +0100)
src/compose.c

index 4e938623695c28f7637a05470b5a3631e4a8ed89..0f25a91eb844f84ad4426cbee16781c98aa4ffff 100644 (file)
@@ -5648,7 +5648,7 @@ static gint compose_write_to_file(Compose *compose, FILE *fp, gint action, gbool
        tmp = end;
 
        /* We make sure that there is a newline at the end. */
-       if (gtk_text_iter_backward_char(&tmp)) {
+       if (action == COMPOSE_WRITE_FOR_SEND && gtk_text_iter_backward_char(&tmp)) {
                chars = gtk_text_buffer_get_text(buffer, &tmp, &end, FALSE);
                if (*chars != '\n') {
                        gtk_text_buffer_insert(buffer, &end, "\n", 1);