X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=src%2Fbindings%2Fpython%2Fbt2%2Fbt2%2Fstream_class.py;h=c22e05a584c6cec260da0fda4634fc039e50ad59;hp=54b5b38bba0587bf1f83e5ff9f3f44e549a32043;hb=d24d56638469189904fb6ddbb3c725817b3e9417;hpb=15caa1ca4fac30bd196602bd136e48fda3892de2 diff --git a/src/bindings/python/bt2/bt2/stream_class.py b/src/bindings/python/bt2/bt2/stream_class.py index 54b5b38b..c22e05a5 100644 --- a/src/bindings/python/bt2/bt2/stream_class.py +++ b/src/bindings/python/bt2/bt2/stream_class.py @@ -103,8 +103,9 @@ class _StreamClass(object._SharedObject, collections.abc.Mapping): def _name(self, name): utils._check_str(name) - ret = native_bt.stream_class_set_name(self._ptr, name) - utils._handle_ret(ret, "cannot set stream class object's name") + status = native_bt.stream_class_set_name(self._ptr, name) + utils._handle_func_status(status, + "cannot set stream class object's name") _name = property(fset=_name) @@ -194,8 +195,8 @@ class _StreamClass(object._SharedObject, collections.abc.Mapping): @id.setter def id(self, id): utils._check_int64(id) - ret = native_bt.stream_class_set_id(self._ptr, id) - utils._handle_ret(ret, "cannot set stream class object's ID") + status = native_bt.stream_class_set_id(self._ptr, id) + utils._handle_func_status(status, "cannot set stream class object's ID") @property def packet_context_field_class(self): @@ -210,9 +211,10 @@ class _StreamClass(object._SharedObject, collections.abc.Mapping): if packet_context_field_class is not None: utils._check_type(packet_context_field_class, bt2.field_class._StructureFieldClass) - ret = native_bt.stream_class_set_packet_context_field_class(self._ptr, - packet_context_field_class._ptr) - utils._handle_ret(ret, "cannot set stream class' packet context field class") + status = native_bt.stream_class_set_packet_context_field_class(self._ptr, + packet_context_field_class._ptr) + utils._handle_func_status(status, + "cannot set stream class' packet context field class") _packet_context_field_class = property(fset=_packet_context_field_class) @@ -231,9 +233,9 @@ class _StreamClass(object._SharedObject, collections.abc.Mapping): bt2.field_class._StructureFieldClass) set_context_fn = native_bt.stream_class_set_event_common_context_field_class - ret = set_context_fn(self._ptr, event_common_context_field_class._ptr) - - utils._handle_ret(ret, "cannot set stream class' event context field type") + status = set_context_fn(self._ptr, event_common_context_field_class._ptr) + utils._handle_func_status(status, + "cannot set stream class' event context field type") _event_common_context_field_class = property(fset=_event_common_context_field_class)