From 854f3d5b85b3a3f3539c2b6b8f26a786c738c7a8 Mon Sep 17 00:00:00 2001 From: Jonathan Li Date: Sun, 27 Aug 2017 01:03:45 +0100 Subject: [PATCH] lilypad: Fix Lock Direction/Input/Both features Regression was introduced in 2ea078beb5aea162188d171345c4b5fe4e99bc6e. Coverity CID 178405. --- plugins/LilyPad/LilyPad.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/LilyPad/LilyPad.cpp b/plugins/LilyPad/LilyPad.cpp index 99c00655f0..34893f9c15 100644 --- a/plugins/LilyPad/LilyPad.cpp +++ b/plugins/LilyPad/LilyPad.cpp @@ -549,7 +549,7 @@ void Update(unsigned int port, unsigned int slot) int cmd = b->command; int state = dev->virtualControlState[b->controlIndex]; if (!(rapidFire & b->rapidFire)) { - if (cmd > 0x0F && cmd != 0x28) { + if ((cmd > 0x0F && cmd < 0x2A && cmd != 0x28) || cmd > 0x2C) { ProcessButtonBinding(b, &s[port][slot], state); } else if ((state >> 15) && !(dev->oldVirtualControlState[b->controlIndex] >> 15)) { if (cmd == 0x0F) { // Mouse