diff options
author | Josh Blum | 2012-11-11 00:03:16 -0800 |
---|---|---|
committer | Josh Blum | 2012-11-11 00:03:16 -0800 |
commit | 284205f5fb4e27583760785aabe97e865450689a (patch) | |
tree | bc58acbe7d32dd3c259bca4613bf1607feefc0f4 /lib/block_task.cpp | |
parent | 6f92f2e145b4cc88b91613c170409ee1b6a27a67 (diff) | |
download | sandhi-284205f5fb4e27583760785aabe97e865450689a.tar.gz sandhi-284205f5fb4e27583760785aabe97e865450689a.tar.bz2 sandhi-284205f5fb4e27583760785aabe97e865450689a.zip |
fixed input fail logic w/ input_queues.is_front_maximal
Diffstat (limited to 'lib/block_task.cpp')
-rw-r--r-- | lib/block_task.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/lib/block_task.cpp b/lib/block_task.cpp index 7507e85..5e1db89 100644 --- a/lib/block_task.cpp +++ b/lib/block_task.cpp @@ -59,8 +59,6 @@ void BlockActor::mark_done(void) void BlockActor::input_fail(const size_t i) { - SBuffer &buff = this->input_queues.front(i); - //input failed, accumulate and try again if (not this->input_queues.is_accumulated(i)) { @@ -77,10 +75,9 @@ void BlockActor::input_fail(const size_t i) } //check that the input is not already maxed - const size_t front_items = buff.length/this->input_items_sizes[i]; - if (front_items >= this->input_configs[i].maximum_items) + if (this->input_queues.is_front_maximal(i)) { - //throw std::runtime_error("input_fail called on maximum_items buffer"); + throw std::runtime_error("input_fail called on maximum_items buffer"); } } |