Commit 80460525 authored by Kenichi Handa's avatar Kenichi Handa
Browse files

(Freplace_match): Use make_multibyte_string or

make_unibyte_string according to the buffer multibyteness.
parent e75c1a57
2004-01-15 Kenichi Handa <handa@m17n.org>
* search.c (Freplace_match): Use make_multibyte_string or
make_unibyte_string according to the buffer multibyteness.
2004-01-14 Stefan Monnier <monnier@iro.umontreal.ca>
* alloc.c (struct interval_block, struct string_block)
......
......@@ -2553,8 +2553,16 @@ since only regular expressions have distinguished subexpressions. */)
}
if (really_changed)
newtext = make_string (substed, substed_len);
{
if (buf_multibyte)
{
int nchars = multibyte_chars_in_text (substed, substed_len);
newtext = make_multibyte_string (substed, nchars, substed_len);
}
else
newtext = make_unibyte_string (substed, substed_len);
}
xfree (substed);
}
......
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