5797 |
int count = specpdl_ptr - specpdl; |
int count = specpdl_ptr - specpdl; |
5798 |
struct gcpro gcpro1; |
struct gcpro gcpro1; |
5799 |
int multibyte = STRING_MULTIBYTE (str); |
int multibyte = STRING_MULTIBYTE (str); |
5800 |
|
Lisp_Object buffer; |
5801 |
|
struct buffer *buf; |
5802 |
|
|
5803 |
record_unwind_protect (Fset_buffer, Fcurrent_buffer ()); |
record_unwind_protect (Fset_buffer, Fcurrent_buffer ()); |
5804 |
record_unwind_protect (code_convert_region_unwind, Qnil); |
record_unwind_protect (code_convert_region_unwind, Qnil); |
5805 |
GCPRO1 (str); |
GCPRO1 (str); |
5806 |
temp_output_buffer_setup (" *code-converting-work*"); |
|
5807 |
set_buffer_internal (XBUFFER (Vstandard_output)); |
buffer = Fget_buffer_create (build_string (" *code-converting-work*")); |
5808 |
|
buf = XBUFFER (buffer); |
5809 |
|
|
5810 |
|
buf->directory = current_buffer->directory; |
5811 |
|
buf->read_only = Qnil; |
5812 |
|
buf->filename = Qnil; |
5813 |
|
buf->undo_list = Qt; |
5814 |
|
buf->overlays_before = Qnil; |
5815 |
|
buf->overlays_after = Qnil; |
5816 |
|
|
5817 |
|
set_buffer_internal (buf); |
5818 |
/* We must insert the contents of STR as is without |
/* We must insert the contents of STR as is without |
5819 |
unibyte<->multibyte conversion. For that, we adjust the |
unibyte<->multibyte conversion. For that, we adjust the |
5820 |
multibyteness of the working buffer to that of STR. */ |
multibyteness of the working buffer to that of STR. */ |
5821 |
Ferase_buffer (); |
Ferase_buffer (); |
5822 |
current_buffer->enable_multibyte_characters = multibyte ? Qt : Qnil; |
buf->enable_multibyte_characters = multibyte ? Qt : Qnil; |
5823 |
|
|
5824 |
insert_from_string (str, 0, 0, |
insert_from_string (str, 0, 0, |
5825 |
XSTRING (str)->size, STRING_BYTES (XSTRING (str)), 0); |
XSTRING (str)->size, STRING_BYTES (XSTRING (str)), 0); |
5826 |
UNGCPRO; |
UNGCPRO; |