Commit 4f8c23b1 authored by Paul Eggert's avatar Paul Eggert
Browse files

Fix crash with insert-file-contents and misdecoded text.

* fileio.c (Finsert_file_contents): Set CODING_MODE_LAST_BLOCK
before invoking decode_coding_gap, since there's just one block.

Fixes: debbugs:16286
parent ed85dee6
2014-01-26 Paul Eggert <eggert@cs.ucla.edu>
Fix crash with insert-file-contents and misdecoded text (Bug#16286).
* fileio.c (Finsert_file_contents): Set CODING_MODE_LAST_BLOCK
before invoking decode_coding_gap, since there's just one block.
2014-01-25 Martin Rudalics <rudalics@gmx.at>
Fix handling of face attributes in Fx_create_frame (Bug#16529).
......
......@@ -4298,6 +4298,7 @@ by calling `format-decode', which see. */)
Z_BYTE -= inserted;
ZV -= inserted;
Z -= inserted;
coding.mode |= CODING_MODE_LAST_BLOCK;
decode_coding_gap (&coding, inserted, inserted);
inserted = coding.produced_char;
coding_system = CODING_ID_NAME (coding.id);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment