From: Simon Marchi Date: Wed, 17 May 2023 19:25:41 +0000 (-0400) Subject: lib: remove duplicated assertion in bt_self_component_source_add_output_port X-Git-Url: http://git.efficios.com/?a=commitdiff_plain;h=643012d55c789824e01f7d2ad5db8063d7c7fae3;hp=643012d55c789824e01f7d2ad5db8063d7c7fae3;p=babeltrace.git lib: remove duplicated assertion in bt_self_component_source_add_output_port The use of BT_ASSERT_PRE_OUTPUT_PORT_NAME_UNIQUE in bt_self_component_source_add_output_port is not necessary, as bt_component_add_output_port checks the same thing: BT_ASSERT_PRE_FROM_FUNC(api_func, "output-port-name-is-unique", bt_component_port_name_is_unique(component->output_ports, name), "Output port name is not unique: name=\"%s\", %![comp-]c", name, component); Remove this use of BT_ASSERT_PRE_OUTPUT_PORT_NAME_UNIQUE, and then remove BT_ASSERT_PRE_OUTPUT_PORT_NAME_UNIQUE itself. Then, make bt_component_port_name_is_unique static to component.c, since it's only used in that file now. Change-Id: Ia341be570596d798179d1937b40726f829cbebfe Reviewed-on: https://review.lttng.org/c/babeltrace/+/10035 Tested-by: jenkins CI-Build: Simon Marchi Reviewed-by: Philippe Proulx ---