Bastien Nocera d5c31c
From a354165e58f937ee12c16ab48ce334b664c8f163 Mon Sep 17 00:00:00 2001
Bastien Nocera d5c31c
From: Bastien Nocera <hadess@hadess.net>
Bastien Nocera d5c31c
Date: Sun, 17 Jun 2012 01:29:01 +0200
Bastien Nocera d5c31c
Subject: [PATCH 3/3] fakehid: Use the same constant as declared
Bastien Nocera d5c31c
Bastien Nocera d5c31c
ps3remote_keymap[] uses 0xff as the max value, so should we.
Bastien Nocera d5c31c
---
Bastien Nocera d5c31c
 input/fakehid.c |    2 +-
Bastien Nocera d5c31c
 1 file changed, 1 insertion(+), 1 deletion(-)
Bastien Nocera d5c31c
Bastien Nocera d5c31c
diff --git a/input/fakehid.c b/input/fakehid.c
Bastien Nocera d5c31c
index a125356..a758413 100644
Bastien Nocera d5c31c
--- a/input/fakehid.c
Bastien Nocera d5c31c
+++ b/input/fakehid.c
Bastien Nocera d5c31c
@@ -335,7 +335,7 @@ static int ps3remote_setup_uinput(struct fake_input *fake,
Bastien Nocera d5c31c
 	}
Bastien Nocera d5c31c
 
Bastien Nocera d5c31c
 	/* enabling keys */
Bastien Nocera d5c31c
-	for (i = 0; i < 256; i++)
Bastien Nocera d5c31c
+	for (i = 0; i < 0xff; i++)
Bastien Nocera d5c31c
 		if (ps3remote_keymap[i] != KEY_RESERVED)
Bastien Nocera d5c31c
 			if (ioctl(fake->uinput, UI_SET_KEYBIT,
Bastien Nocera d5c31c
 						ps3remote_keymap[i]) < 0) {
Bastien Nocera d5c31c
-- 
Bastien Nocera d5c31c
1.7.10
Bastien Nocera d5c31c