summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarcus Fritzsch <marcus_fritzsch@mentor.com>2017-09-04 16:05:06 +0200
committerMarcus Fritzsch <marcus_fritzsch@mentor.com>2017-09-14 14:04:51 +0200
commit0ffdfa88ee21c533e2b3f3627c088ca12fc661d2 (patch)
tree000a49dcf2a88c24ec1c68372b703e2573bb77c4
parente33f046a281dd88d9c37a34c849bbad6148a95b5 (diff)
Call event handler only if event-label matches
Signed-off-by: Marcus Fritzsch <marcus_fritzsch@mentor.com>
-rw-r--r--AFBClient.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/AFBClient.cpp b/AFBClient.cpp
index 99f22bd..cee49ad 100644
--- a/AFBClient.cpp
+++ b/AFBClient.cpp
@@ -403,7 +403,9 @@ void AFBClient::Impl::event(char const *et, char const *label) {
auto i = this->handlers.find(oet.second);
if (i != this->handlers.end()) {
- i->second(label);
+ if (this->labels.find(label) != this->labels.end()) {
+ i->second(label);
+ }
}
}