mirror of
https://github.com/MariaDB/server.git
synced 2026-05-03 13:45:34 +02:00
MDEV-6752 Trailing incomplete characters are not replaced to question marks on conversion
This commit is contained in:
parent
391fddf660
commit
8286bcd721
5 changed files with 96 additions and 4 deletions
|
|
@ -1066,7 +1066,14 @@ my_convert_internal(char *to, uint32 to_length,
|
|||
wc= '?';
|
||||
}
|
||||
else
|
||||
break; // Not enough characters
|
||||
{
|
||||
if ((uchar *) from >= from_end)
|
||||
break; /* End of line */
|
||||
/* Incomplete byte sequence */
|
||||
error_count++;
|
||||
from++;
|
||||
wc= '?';
|
||||
}
|
||||
|
||||
outp:
|
||||
if ((cnvres= (*wc_mb)(to_cs, wc, (uchar*) to, to_end)) > 0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue