diff options
| author | Ted Ross <tross@apache.org> | 2010-09-21 21:48:41 +0000 |
|---|---|---|
| committer | Ted Ross <tross@apache.org> | 2010-09-21 21:48:41 +0000 |
| commit | d47927b3e150057f6d615a0d00c8eff6c83320ac (patch) | |
| tree | 6cf1da8bd7a46fd3cef8251af94f88bbad0e627d /qpid/cpp/bindings/qmf2/python/python.i | |
| parent | 81414cc0fb52efbd77e3e3bc83ed0c5dcb7fe83a (diff) | |
| download | qpid-python-d47927b3e150057f6d615a0d00c8eff6c83320ac.tar.gz | |
QMFv2 Additions:
- QMFv2 schema encoding completed
- Schema queries handled by the agent and initiated by the console by user request
- Full query support with predicates evaluated on the agent (regex not yet implemented)
- Agent filtering in the console
- Agent aging in the console
- Unit tests
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@999662 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp/bindings/qmf2/python/python.i')
| -rw-r--r-- | qpid/cpp/bindings/qmf2/python/python.i | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/qpid/cpp/bindings/qmf2/python/python.i b/qpid/cpp/bindings/qmf2/python/python.i index 7d83465bb3..02dd1632b0 100644 --- a/qpid/cpp/bindings/qmf2/python/python.i +++ b/qpid/cpp/bindings/qmf2/python/python.i @@ -23,13 +23,16 @@ /* Define the general-purpose exception handling */ %exception { + std::string error; + Py_BEGIN_ALLOW_THREADS; try { - Py_BEGIN_ALLOW_THREADS $action - Py_END_ALLOW_THREADS + } catch (qpid::types::Exception& ex) { + error = ex.what(); } - catch (qpid::types::Exception& ex) { - PyErr_SetString(PyExc_RuntimeError, ex.what()); + Py_END_ALLOW_THREADS; + if (!error.empty()) { + PyErr_SetString(PyExc_RuntimeError, error.c_str()); return NULL; } } |
