From bebf5a4a72d205a1a05c7dc70d9bef240cfc477f Mon Sep 17 00:00:00 2001 From: michaelld Date: Sat, 31 Jan 2009 02:48:58 +0000 Subject: Merged in misc_fixes branch. git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@10350 221aa14e-8319-0410-a670-987f0aec2ac5 --- gnuradio-core/src/lib/runtime/gr_msg_queue.i | 6 +++--- gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.i | 5 ++--- 2 files changed, 5 insertions(+), 6 deletions(-) (limited to 'gnuradio-core/src/lib/runtime') diff --git a/gnuradio-core/src/lib/runtime/gr_msg_queue.i b/gnuradio-core/src/lib/runtime/gr_msg_queue.i index 68dbfd645..254a7a940 100644 --- a/gnuradio-core/src/lib/runtime/gr_msg_queue.i +++ b/gnuradio-core/src/lib/runtime/gr_msg_queue.i @@ -39,7 +39,7 @@ class gr_msg_queue : public gr_msg_handler { int d_count; public: - gr_msg_queue(); + gr_msg_queue(unsigned int limit); ~gr_msg_queue(); //! Generic msg_handler method: insert the message. @@ -87,7 +87,7 @@ public: * functions into the gr.msg_queue wrapper class, so that everything * appears normal. (An evil laugh is heard in the distance...) */ -%inline { +%inline %{ gr_message_sptr gr_py_msg_queue__delete_head(gr_msg_queue_sptr q) { gr_message_sptr msg; Py_BEGIN_ALLOW_THREADS; // release global interpreter lock @@ -101,7 +101,7 @@ public: q->insert_tail(msg); // possibly blocking call Py_END_ALLOW_THREADS; // acquire global interpreter lock } -} +%} // smash in new python delete_head and insert_tail methods... %pythoncode %{ diff --git a/gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.i b/gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.i index fb2ff0d7f..5e9032449 100644 --- a/gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.i +++ b/gnuradio-core/src/lib/runtime/gr_single_threaded_scheduler.i @@ -42,11 +42,10 @@ class gr_single_threaded_scheduler { gr_single_threaded_scheduler (const std::vector &modules); }; -%inline { +%inline %{ void sts_pyrun (gr_single_threaded_scheduler_sptr s) { Py_BEGIN_ALLOW_THREADS; // release global interpreter lock s->run (); Py_END_ALLOW_THREADS; // acquire global interpreter lock } -} - +%} -- cgit