Revision bebf5a4a gnuradio-core/src/lib/runtime/gr_msg_queue.i
| b/gnuradio-core/src/lib/runtime/gr_msg_queue.i | ||
|---|---|---|
| 39 | 39 |
int d_count; |
| 40 | 40 |
|
| 41 | 41 |
public: |
| 42 |
gr_msg_queue(); |
|
| 42 |
gr_msg_queue(unsigned int limit);
|
|
| 43 | 43 |
~gr_msg_queue(); |
| 44 | 44 |
|
| 45 | 45 |
//! Generic msg_handler method: insert the message. |
| ... | ... | |
| 87 | 87 |
* functions into the gr.msg_queue wrapper class, so that everything |
| 88 | 88 |
* appears normal. (An evil laugh is heard in the distance...) |
| 89 | 89 |
*/ |
| 90 |
%inline {
|
|
| 90 |
%inline %{
|
|
| 91 | 91 |
gr_message_sptr gr_py_msg_queue__delete_head(gr_msg_queue_sptr q) {
|
| 92 | 92 |
gr_message_sptr msg; |
| 93 | 93 |
Py_BEGIN_ALLOW_THREADS; // release global interpreter lock |
| ... | ... | |
| 101 | 101 |
q->insert_tail(msg); // possibly blocking call |
| 102 | 102 |
Py_END_ALLOW_THREADS; // acquire global interpreter lock |
| 103 | 103 |
} |
| 104 |
} |
|
| 104 |
%}
|
|
| 105 | 105 |
|
| 106 | 106 |
// smash in new python delete_head and insert_tail methods... |
| 107 | 107 |
%pythoncode %{
|
Also available in: Unified diff