OSDN Git Service

msm: msm_bus: limit max chars read by sscanf
authorDavid Dai <daidavid1@codeaurora.org>
Thu, 3 Nov 2016 22:00:43 +0000 (15:00 -0700)
committerDavid Dai <daidavid1@codeaurora.org>
Thu, 3 Nov 2016 22:01:17 +0000 (15:01 -0700)
commitd71222ae41572b5ad267744983db8d3d81a21aaf
treed91852df3c2795ec405adbdd5ad6cf85b14e1d27
parent758693b4a6d94a0724081578d24f6ba1cc449255
msm: msm_bus: limit max chars read by sscanf

Current bus_floor_vote_store_api does not limit/check
the size of the string in input, allowing stack overflow.
Specify the max number of characters read allowable to
the size of destination buffer.

CRs-Fixed: 1050455
Change-Id: Idd409e3e38cfb01b28fa24543112d6bb206314ff
Signed-off-by: David Dai <daidavid1@codeaurora.org>
drivers/soc/qcom/msm_bus/msm_bus_dbg_voter.c