mirror of https://github.com/mpv-player/mpv
getch2: Doing it right this time
getch2_pos should be set to 1, not 0, when backtracking. Avoids the possible infinite loop but correctly.
This commit is contained in:
parent
c36a5e0f36
commit
0cfc382355
|
@ -378,7 +378,7 @@ bool getch2(struct input_ctx *input_ctx)
|
|||
continue; /* need more bytes to disambiguate */
|
||||
} else {
|
||||
/* backtrack, send as UTF-8 */
|
||||
getch2_pos = 0;
|
||||
getch2_pos = 1;
|
||||
c = getch2_buf[0];
|
||||
}
|
||||
utf8_len = bstr_parse_utf8_code_length(c);
|
||||
|
|
Loading…
Reference in New Issue