aboutsummaryrefslogtreecommitdiffstats
path: root/CAN-binder/low-can-binding/utils/signals.hpp
diff options
context:
space:
mode:
authorRomain Forlot <romain.forlot@iot.bzh>2017-04-24 09:23:17 +0200
committerRomain Forlot <romain.forlot@iot.bzh>2017-04-24 09:23:17 +0200
commit9e72f805168ae60919117c98dc1ab6c7441873ac (patch)
tree3ebbf7401dd929467fbae40af055d93101bf3a8d /CAN-binder/low-can-binding/utils/signals.hpp
parent118c1d1edead3dabf0867125027281ccb776b9a3 (diff)
Fix: Avoid returning 2 results for 1 signal.
Either returning signal with search against generic_name either against name, not both. Change-Id: I597718d04c99d098973442b4174e735e813c9b94 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'CAN-binder/low-can-binding/utils/signals.hpp')
-rw-r--r--CAN-binder/low-can-binding/utils/signals.hpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/CAN-binder/low-can-binding/utils/signals.hpp b/CAN-binder/low-can-binding/utils/signals.hpp
index d2e9205c..2eae7e94 100644
--- a/CAN-binder/low-can-binding/utils/signals.hpp
+++ b/CAN-binder/low-can-binding/utils/signals.hpp
@@ -61,7 +61,7 @@ namespace utils
{
if(::fnmatch(key.c_str(), s.get_generic_name().c_str(), FNM_CASEFOLD) == 0)
found_signals.push_back(&s);
- if(::fnmatch(key.c_str(), s.get_name().c_str(), FNM_CASEFOLD) == 0)
+ else if(::fnmatch(key.c_str(), s.get_name().c_str(), FNM_CASEFOLD) == 0)
found_signals.push_back(&s);
}
}