Skip to content
Permalink
Browse files

Fix possible failure to derive certain features

  • Loading branch information...
garbear committed Oct 19, 2016
1 parent 0da70a1 commit 39751ff38ee2f63aeac20d2e4d7d7cbad712126a
Showing with 3 additions and 0 deletions.
  1. +3 −0 src/buttonmapper/ButtonMapper.cpp
@@ -113,6 +113,9 @@ void CButtonMapper::MergeFeatures(FeatureVector& features, const FeatureVector&
{
for (const auto& primitive : feature.Primitives())
{
if (primitive.Type() == JOYSTICK_DRIVER_PRIMITIVE_TYPE_UNKNOWN)
continue;

if (std::find(newPrimitives.begin(), newPrimitives.end(), primitive) != newPrimitives.end())
return true; // Found primitive
}

0 comments on commit 39751ff

Please sign in to comment.
You can’t perform that action at this time.