python/redland-typemap.i
raw| 1 | %exception { |
| 2 | $action |
| 3 | if(librdf_python_error_message) { |
| 4 | PyErr_SetString(PyRedland_Error, librdf_python_error_message); |
| 5 | free(librdf_python_error_message); |
| 6 | librdf_python_error_message=NULL; |
| 7 | SWIG_fail; |
| 8 | } |
| 9 | if(librdf_python_warning_message) { |
| 10 | PyErr_Warn(PyRedland_Warning, librdf_python_warning_message); |
| 11 | free(librdf_python_warning_message); |
| 12 | librdf_python_warning_message=NULL; |
| 13 | } |
| 14 | } |