lkml.org 
[lkml]   [2018]   [Dec]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Subject[PATCH 0/2] vsprintf Stop using obsolete simple_strtoul()
Date
Hi,
We've fixed a bug with sscanf(). When passing in a 16-digit hex-string like so:

sscanf("fafafafa0b0b0b0b", "%8x%8x", &hi, &lo)

The resulting value in hi is always 0. This is because vsscanf() uses the
obsolete and broken functions simple_strtoul() and simple_strtoull(), which we
have replaced.

Many thanks,
Thomas

Thomas Preston (2):
vsprintf: Specify type for union val members
vsprintf: Stop using obsolete simple_strtoul()

lib/vsprintf.c | 66 ++++++++++++++++++++++++++++++++++++++--------------------
1 file changed, 43 insertions(+), 23 deletions(-)

--
2.11.0

\
 
 \ /
  Last update: 2018-12-11 16:21    [W:0.051 / U:0.052 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site