From 149d86611985b7a382994ac684d555660927e8d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Nusser?= Date: Tue, 14 Jun 2016 23:16:41 +0200 Subject: Make code from last commit a little more explicit. --- src/inputprocessor.cc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/inputprocessor.cc b/src/inputprocessor.cc index b59f0e5..af07dad 100644 --- a/src/inputprocessor.cc +++ b/src/inputprocessor.cc @@ -132,7 +132,10 @@ bool InputProcessor::processOnset(event_t& event, for(auto& filter : filters) { - if(!filter->filter(event, event.offset + pos)) + // This line might change the 'event' variable + bool keep = filter->filter(event, event.offset + pos); + + if(!keep) { return false; // Skip event completely } -- cgit v1.2.3