summaryrefslogtreecommitdiff
path: root/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp')
-rw-r--r--Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp b/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
index 26c2d34474..d1efdf1d93 100644
--- a/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
+++ b/Source/Core/InputCommon/Src/ControllerInterface/ControllerInterface.cpp
@@ -505,6 +505,9 @@ ControllerInterface::Device::Control* ControllerInterface::InputReference::Detec
unsigned int time = 0;
bool* const states = new bool[device->Inputs().size()];
+ if (device->Inputs().size() == 0)
+ return NULL;
+
// get starting state of all inputs,
// so we can ignore those that were activated at time of Detect start
std::vector<Device::Input*>::const_iterator