diff mbox

[2/4] ir-ctl: "ir-ctl -S rc6_mce:0x800f0410" does not work on 32-bit

Message ID 20170803214231.9334-3-sean@mess.org (mailing list archive)
State New, archived
Headers show

Commit Message

Sean Young Aug. 3, 2017, 9:42 p.m. UTC
0x800f0410 does not fit in 32-bit signed long.

Signed-off-by: Sean Young <sean@mess.org>
---
 utils/ir-ctl/ir-ctl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox

Patch

diff --git a/utils/ir-ctl/ir-ctl.c b/utils/ir-ctl/ir-ctl.c
index 3d66063a..562a05da 100644
--- a/utils/ir-ctl/ir-ctl.c
+++ b/utils/ir-ctl/ir-ctl.c
@@ -152,7 +152,7 @@  static int strtoint(const char *p, const char *unit)
 static bool strtoscancode(const char *p, unsigned *ret)
 {
 	char *end;
-	long arg = strtol(p, &end, 0);
+	long long arg = strtoll(p, &end, 0);
 	if (end == NULL || end[0] != 0)
 		return false;