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

Commit 4ba84071 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "icnss: NULL terminate the fw build timestamp string"

parents a7306e91 4b8b1114
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -3186,6 +3186,8 @@ EXPORT_SYMBOL(icnss_disable_irq);

int icnss_get_soc_info(struct device *dev, struct icnss_soc_info *info)
{
	char *fw_build_timestamp = NULL;

	if (!penv || !dev) {
		icnss_pr_err("Platform driver not initialized\n");
		return -EINVAL;
@@ -3198,6 +3200,8 @@ int icnss_get_soc_info(struct device *dev, struct icnss_soc_info *info)
	info->board_id = penv->board_info.board_id;
	info->soc_id = penv->soc_info.soc_id;
	info->fw_version = penv->fw_version_info.fw_version;
	fw_build_timestamp = penv->fw_version_info.fw_build_timestamp;
	fw_build_timestamp[QMI_WLFW_MAX_TIMESTAMP_LEN_V01] = '\0';
	strlcpy(info->fw_build_timestamp,
		penv->fw_version_info.fw_build_timestamp,
		QMI_WLFW_MAX_TIMESTAMP_LEN_V01 + 1);