Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c2e5768f authored by Colin Ian King's avatar Colin Ian King Committed by Ian Maund
Browse files

wil6210: increase cmd buffer size to avoid sscanf buffer overflow



cppcheck detected a buffer overflow:

[drivers/net/wireless/ath/wil6210/debugfs.c:634]: (error) Width 8
  given in format string (no. 1) is larger than destination buffer
  'cmd[8]', use %7s to prevent overflowing it.

For the current %8s sscanf we require cmd to be 9 chars long
so increase it by 1 byte to prevent the sscan overflow (rather
than reduce the %8s specifier to %7s as cppcheck recommends).

Change-Id: I4caf8bf6ba407597fb5a1952572a47b2beacfdb8
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Acked-by: default avatarVladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
Git-commit: 2a19f7765bd90a56f3916a603e25b57b3b087480
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-testing.git


Signed-off-by: default avatarHamad Kadmany <hkadmany@codeaurora.org>
parent 37bc52a5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment