[U-Boot] [PATCH v2 1/1] lib: vsprintf: avoid overflow printing UTF16 strings
Simon Glass
sjg at chromium.org
Sun Feb 10 10:48:40 UTC 2019
On Sun, 10 Feb 2019 at 04:11, Heinrich Schuchardt <xypron.glpk at gmx.de> wrote:
>
> We have to ensure while printing UTF16 strings that we do not exceed the
> end of the print buffer.
>
> Signed-off-by: Heinrich Schuchardt <xypron.glpk at gmx.de>
> ---
> v2
> Use the exact UTF8 length of the converted UTF16 character when
> checking if sufficient space is remaining in the buffer. This
> avoids missing up to 2 characters.
> ---
> lib/vsprintf.c | 10 +++++++---
> 1 file changed, 7 insertions(+), 3 deletions(-)
Reviewed-by: Simon Glass <sjg at chromium.org>
More information about the U-Boot
mailing list