summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
m---------gnuradio0
-rw-r--r--lib/block_allocator.cpp4
-rw-r--r--lib/buffer_queue_circ.cpp1
3 files changed, 5 insertions, 0 deletions
diff --git a/gnuradio b/gnuradio
-Subproject 76b0f3702ae0532f1b83ffe050852ba729c7e27
+Subproject 3882e6a6fc75b021a10c3ce91bf7c39ef33d4e4
diff --git a/lib/block_allocator.cpp b/lib/block_allocator.cpp
index 6dc5022..1f4490c 100644
--- a/lib/block_allocator.cpp
+++ b/lib/block_allocator.cpp
@@ -80,6 +80,10 @@ void BlockActor::handle_top_alloc(const TopAllocMessage &, const Theron::Address
this->output_queues.set_buffer_queue(i, queue);
InputAllocMessage message;
+ //new token for the downstream allocator
+ //so when the downstream overrides, old token gets reset
+ token = SBufferToken(new SBufferDeleter(deleter));
+ config.token = token;
message.config = config;
message.token = token;
this->post_downstream(i, message);
diff --git a/lib/buffer_queue_circ.cpp b/lib/buffer_queue_circ.cpp
index 336f17c..61cba1f 100644
--- a/lib/buffer_queue_circ.cpp
+++ b/lib/buffer_queue_circ.cpp
@@ -120,6 +120,7 @@ void BufferQueueCirc::push(const SBuffer &buff)
//is it my buffer? otherwise dont keep it
if (buff->config.token.lock() != _token) return;
+ ASSERT(buff.get_user_index() < _returned_buffers.size());
_returned_buffers[buff.get_user_index()] = buff;
//ack starting at the expected index and up