Browse Source

qcacld-3.0: Avoid info leak in hdd_driver_rxfilter_comand_handler

In hdd_driver_rxfilter_comand_handler(), when kstrtou8() fails to parse
the input string, the value of an uninitialized @type local is logged.
To avoid leaking stack memory, avoid logging the value of @type if the
parsing fails.

Change-Id: I46b21cdb138927b3edc406014450447c58a0d977
CRs-Fixed: 2221085
Dustin Brown 7 years ago
parent
commit
933cd2a72f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      core/hdd/src/wlan_hdd_ioctl.c

+ 1 - 1
core/hdd/src/wlan_hdd_ioctl.c

@@ -6194,7 +6194,7 @@ static int hdd_driver_rxfilter_comand_handler(uint8_t *command,
 		value = command + 13;
 	ret = kstrtou8(value, 10, &type);
 	if (ret < 0) {
-		hdd_err("kstrtou8 failed invalid input value %d", type);
+		hdd_err("kstrtou8 failed invalid input value");
 		return -EINVAL;
 	}