diff options
author | David Robillard <d@drobilla.net> | 2011-10-09 20:29:05 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2011-10-09 20:29:05 +0000 |
commit | ca12acb6cb9b1f7618b88f2c95efd8ab275e1f57 (patch) | |
tree | a28782c7b6283578bd338e2c3a7e4afd21b8bff9 /src | |
parent | 59d6a7095c79a84475b95cb4121d9e3845806d16 (diff) | |
download | ingen-ca12acb6cb9b1f7618b88f2c95efd8ab275e1f57.tar.gz ingen-ca12acb6cb9b1f7618b88f2c95efd8ab275e1f57.tar.bz2 ingen-ca12acb6cb9b1f7618b88f2c95efd8ab275e1f57.zip |
Attempted blind fix for #778.
git-svn-id: http://svn.drobilla.net/lad/trunk/ingen@3538 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src')
-rw-r--r-- | src/server/PostProcessor.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/server/PostProcessor.cpp b/src/server/PostProcessor.cpp index 3cd05992..d9195027 100644 --- a/src/server/PostProcessor.cpp +++ b/src/server/PostProcessor.cpp @@ -73,11 +73,13 @@ PostProcessor::process() /* Process audio thread generated events */ Driver* driver = _engine.driver(); if (driver) { - Notification note; - const uint32_t read_space = driver->context().event_sink().read_space(); + Raul::RingBuffer& event_sink = driver->context().event_sink(); + const uint32_t read_space = event_sink.read_space(); + Notification note; for (uint32_t i = 0; i < read_space; i += sizeof(note)) { - driver->context().event_sink().read(sizeof(note), ¬e); - Notification::post_process(note, _engine); + if (event_sink.read(sizeof(note), ¬e) == sizeof(note)) { + Notification::post_process(note, _engine); + } } } |