linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 2/2]iw: UNSPECIFIED_CHAR_IN_COND : Fix
@ 2015-11-26  9:11 Rahul Jain
  2015-11-26  9:36 ` Johannes Berg
  0 siblings, 1 reply; 2+ messages in thread
From: Rahul Jain @ 2015-11-26  9:11 UTC (permalink / raw)
  To: johannes; +Cc: linux-wireless, Amit Khatri, Rahul Jain

From: Amit Khatri <amit.khatri@samsung.com>

Signed-off-by: Amit Khatri <amit.khatri@samsung.com>
Signed-off-by: Rahul Jain <rahul.jain@samsung.com>
---
 util.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/util.c b/util.c
index 8fd14bd..7edc830 100644
--- a/util.c
+++ b/util.c
@@ -330,11 +330,13 @@ void print_ssid_escaped(const uint8_t len, const uint8_t *data)
 
 static int hex2num(char digit)
 {
+	unsigned char temp;
+	temp = digit;
 	if (!isxdigit(digit))
 		return -1;
 	if (isdigit(digit))
 		return digit - '0';
-	return tolower(digit) - 'a' + 10;
+	return tolower(temp) - 'a' + 10;
 }
 
 static int hex2byte(char *hex)
-- 
1.9.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-11-26  9:36 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-11-26  9:11 [PATCH 2/2]iw: UNSPECIFIED_CHAR_IN_COND : Fix Rahul Jain
2015-11-26  9:36 ` Johannes Berg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).