From a99f8ac8cc9a15ab608081c10a7733fce125e276 Mon Sep 17 00:00:00 2001 From: Jiří Pinkava <j-pi@seznam.cz> Date: Thu, 9 Apr 2015 08:55:04 +0200 Subject: runtime: fix state handling in top_block d_state is intended to track running state of top block. * initial state is IDLE * set state to RUNNING when start() is called * set state to IDLE when stop() is called * set state to IDLE when all work is done (reqires call of wait()) * unlock() resume/start execution only if state is RUNNING --- gnuradio-runtime/lib/top_block_impl.h | 1 + 1 file changed, 1 insertion(+) (limited to 'gnuradio-runtime/lib/top_block_impl.h') diff --git a/gnuradio-runtime/lib/top_block_impl.h b/gnuradio-runtime/lib/top_block_impl.h index 1ac5136ddf..de0a67b4c1 100644 --- a/gnuradio-runtime/lib/top_block_impl.h +++ b/gnuradio-runtime/lib/top_block_impl.h @@ -82,6 +82,7 @@ namespace gr { gr::thread::mutex d_mutex; // protects d_state and d_lock_count tb_state d_state; int d_lock_count; + bool d_retry_wait; boost::condition_variable d_lock_cond; int d_max_noutput_items; -- cgit v1.2.3