unifikey: fix kasan bug reported in name_store [1/1]
authorJiamin Ma <jiamin.ma@amlogic.com>
Fri, 19 Apr 2019 00:15:47 +0000 (08:15 +0800)
committerTao Zeng <tao.zeng@amlogic.com>
Fri, 19 Apr 2019 08:17:30 +0000 (01:17 -0700)
commit540cac991ac9a6c7cb68d2a6c035431cb3445829
treea9365ce32db73688c982aff5d5311d69661c5c17
parentb18e61ed202020538bc674aa691bfdfed5b26d13
unifikey: fix kasan bug reported in name_store [1/1]

PD#SWPL-7326

Problem:
slab-out-of-bounds in strlen called by name_store

Solution:
Make sure the string passed to strlen is always '\0'
ended

Verify:
Locally

Change-Id: Ifd78a100c0e34ff9afb527ebe7b044ceb5c3505e
Signed-off-by: Jiamin Ma <jiamin.ma@amlogic.com>
drivers/amlogic/unifykey/unifykey.c