X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=src%2Fbindings%2Fpython%2Fbt2%2Fbt2%2Fnative_bt_component_class.i;h=90fc4abae8f1b5a18e9d51d58fda453c18cf889d;hp=e71e6bf8e7ed4d1f3e6328fe113ad6ef07e48569;hb=76b6c2f71a485f0cc9b766e1a54b9f7330ccd907;hpb=07041dafaae18146e189a70c33a8a0695cbdd813 diff --git a/src/bindings/python/bt2/bt2/native_bt_component_class.i b/src/bindings/python/bt2/bt2/native_bt_component_class.i index e71e6bf8..90fc4aba 100644 --- a/src/bindings/python/bt2/bt2/native_bt_component_class.i +++ b/src/bindings/python/bt2/bt2/native_bt_component_class.i @@ -97,7 +97,7 @@ static PyObject *py_mod_bt2_exc_error_type = NULL; static PyObject *py_mod_bt2_exc_memory_error = NULL; static PyObject *py_mod_bt2_exc_try_again_type = NULL; static PyObject *py_mod_bt2_exc_stop_type = NULL; -static PyObject *py_mod_bt2_exc_invalid_object_type = NULL; +static PyObject *py_mod_bt2_exc_unknown_object_type = NULL; static void bt_bt2_cc_init_from_bt2(void) @@ -124,9 +124,9 @@ void bt_bt2_cc_init_from_bt2(void) py_mod_bt2_exc_stop_type = PyObject_GetAttrString(py_mod_bt2, "Stop"); BT_ASSERT(py_mod_bt2_exc_stop_type); - py_mod_bt2_exc_invalid_object_type = - PyObject_GetAttrString(py_mod_bt2, "InvalidObject"); - BT_ASSERT(py_mod_bt2_exc_invalid_object_type); + py_mod_bt2_exc_unknown_object_type = + PyObject_GetAttrString(py_mod_bt2, "UnknownObject"); + BT_ASSERT(py_mod_bt2_exc_unknown_object_type); } static @@ -149,7 +149,7 @@ void bt_bt2_cc_exit_handler(void) Py_XDECREF(py_mod_bt2_exc_error_type); Py_XDECREF(py_mod_bt2_exc_try_again_type); Py_XDECREF(py_mod_bt2_exc_stop_type); - Py_XDECREF(py_mod_bt2_exc_invalid_object_type); + Py_XDECREF(py_mod_bt2_exc_unknown_object_type); } @@ -388,8 +388,8 @@ int py_exc_to_status(bt_self_component_class *self_component_class, py_mod_bt2_exc_stop_type)) { status = __BT_FUNC_STATUS_END; } else if (PyErr_GivenExceptionMatches(exc, - py_mod_bt2_exc_invalid_object_type)) { - status = __BT_FUNC_STATUS_INVALID_OBJECT; + py_mod_bt2_exc_unknown_object_type)) { + status = __BT_FUNC_STATUS_UNKNOWN_OBJECT; } else { /* Unknown exception: convert to general error */ log_exception_and_maybe_append_error(BT_LOG_WARNING, true,