diff options
author | Tim O'Shea <tim.oshea753@gmail.com> | 2014-02-05 17:04:16 -0500 |
---|---|---|
committer | Tom Rondeau <tom@trondeau.com> | 2014-02-16 11:32:23 -0500 |
commit | f43151d00e7f502281259952397e699f4beb4f08 (patch) | |
tree | f90f933c9ca8007c27c37573c9362ea900cef1a4 /gnuradio-runtime/lib/tpb_thread_body.cc | |
parent | 295ba353abebfedf90ece523343bcfeea2c2149d (diff) |
runtime: warn when dropping asynchronous messages due to full asynch message queue, increase default asynch max buffer depth to 8192
Diffstat (limited to 'gnuradio-runtime/lib/tpb_thread_body.cc')
-rw-r--r-- | gnuradio-runtime/lib/tpb_thread_body.cc | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/gnuradio-runtime/lib/tpb_thread_body.cc b/gnuradio-runtime/lib/tpb_thread_body.cc index f6f09a9c3e..ea5d80a9dc 100644 --- a/gnuradio-runtime/lib/tpb_thread_body.cc +++ b/gnuradio-runtime/lib/tpb_thread_body.cc @@ -73,8 +73,10 @@ namespace gr { else { // If we don't have a handler but are building up messages, // prune the queue from the front to keep memory in check. - if(block->nmsgs(i.first) > max_nmsgs) + if(block->nmsgs(i.first) > max_nmsgs){ + GR_LOG_WARN(LOG,"asynchronous message buffer overflowing, dropping message"); msg = block->delete_head_nowait(i.first); + } } } @@ -121,8 +123,10 @@ namespace gr { else { // leave msg in queue if no handler is defined // start dropping if we have too many - if(block->nmsgs(i.first) > max_nmsgs) + if(block->nmsgs(i.first) > max_nmsgs){ + GR_LOG_WARN(LOG,"asynchronous message buffer overflowing, dropping message"); msg = block->delete_head_nowait(i.first); + } } } if (d->done()) { @@ -152,8 +156,10 @@ namespace gr { else { // leave msg in queue if no handler is defined // start dropping if we have too many - if(block->nmsgs(i.first) > max_nmsgs) + if(block->nmsgs(i.first) > max_nmsgs){ + GR_LOG_WARN(LOG,"asynchronous message buffer overflowing, dropping message"); msg = block->delete_head_nowait(i.first); + } } } } |