Irssi didn't work properly if read() returned only partial utf8 character

string.


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2544 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2002-03-09 17:54:38 +00:00 committed by cras
commit 95d8b617ae

View file

@ -630,9 +630,9 @@ int term_gets(unichar *buffer, int size)
if (i >= term_inbuf_pos)
term_inbuf_pos = 0;
else {
else if (i > 0) {
memmove(term_inbuf+i, term_inbuf, term_inbuf_pos-i);
term_inbuf_pos = i;
term_inbuf_pos -= i;
}
}