qcacld-3.0: Buffer overflow while parsing setrmcrate command
There is a buffer overflow while using sscanf.
To resolve this, use sscanf according to buffer length.
Change-Id: Ida2444b42ef6b73ea6f55735166df941158a6e50
CRs-Fixed: 2059779
diff --git a/core/hdd/src/wlan_hdd_ioctl.c b/core/hdd/src/wlan_hdd_ioctl.c
index bde9803..ba76227 100644
--- a/core/hdd/src/wlan_hdd_ioctl.c
+++ b/core/hdd/src/wlan_hdd_ioctl.c
@@ -316,7 +316,7 @@
if ('\0' == *inPtr)
return 0;
- v = sscanf(inPtr, "%32s ", buf);
+ v = sscanf(inPtr, "%31s ", buf);
if (1 != v)
return -EINVAL;