wifi-test-suite: Fix build with clang

Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Khem Raj 2022-08-31 19:43:35 -07:00
parent aec96f2377
commit fa3ccbc37d
2 changed files with 34 additions and 1 deletions

View File

@ -0,0 +1,32 @@
From 2b7d6cf62296ff4e25e5ad909aa39a257bf9ff78 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Wed, 31 Aug 2022 19:37:35 -0700
Subject: [PATCH] wfa_cmdproc: Store return value into location
Fixes
| wfa_cmdproc.c:100:20: error: incompatible integer to pointer conversion assigning to 'int *' from 'int' [-Wint-conversion]
| paramValue = atoi(str);
| ^ ~~~~~~~~~
Upstream-Status: Submitted [https://github.com/Wi-FiTestSuite/Wi-FiTestSuite-Linux-DUT/pull/57]
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
lib/wfa_cmdproc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/wfa_cmdproc.c b/lib/wfa_cmdproc.c
index 9f5fd16..49a3f16 100644
--- a/lib/wfa_cmdproc.c
+++ b/lib/wfa_cmdproc.c
@@ -97,7 +97,7 @@ int getParamValueInt(char *pcmdStr, char *pParam, int *paramValue)
if(strcasecmp(pcmdStr, pParam) == 0)
{
str = strtok_r(NULL, ",", &pcmdStr);
- paramValue = atoi(str);
+ *paramValue = atoi(str);
return 0;
}
return -1;
--
2.37.3

View File

@ -8,13 +8,14 @@ LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=0542427ed5c315ca34aa09ae7a85ed32"
SECTION = "test"
S = "${WORKDIR}/git"
SRCREV = "2da947374c8324f88a0e2155aeba4cf75464b0d8"
SRCREV = "12e85fbeca8ca21a632d18e55089a8a7606d64aa"
SRC_URI = "git://github.com/Wi-FiTestSuite/Wi-FiTestSuite-Linux-DUT.git;branch=master;protocol=https \
file://0001-Use-toolchain-from-environment-variables.patch \
file://0002-Add-missing-include-removes-unnedded-stuff-and-add-n.patch \
file://0003-fix-path-to-usr-sbin-for-script-and-make-script-for-.patch \
file://0004-run-ranlib-per-library-and-use-AR.patch \
file://fno-common.patch \
file://0001-wfa_cmdproc-Store-return-value-into-location.patch \
"
# to avoid host path QA error