- clock_class = bt_ctf_clock_value_get_class(clock_value);
- ret = bt_clock_class_priority_map_get_clock_class_priority(
- inactivity_notification->cc_prio_map, clock_class, &prio);
- if (ret) {
- BT_LOGW("Clock value's class is not mapped to a priority within the scope of the inactivity notification: "
- "notif-addr=%p, cc-prio-map-addr=%p, "
- "clock-class-addr=%p, clock-class-name=\"%s\", "
- "clock-value-addr=%p",
- inactivity_notification,
- inactivity_notification->cc_prio_map,
- clock_class, bt_ctf_clock_class_get_name(clock_class),
- clock_value);
- ret = -1;
- goto end;
- }
-
+ BT_ASSERT_PRE(cc_prio_map_contains_clock_class(
+ inactivity_notification->cc_prio_map, clock_value->clock_class),
+ "Clock value's class is not mapped to a priority within the scope of the inactivity notification: "
+ "notif-addr=%p, cc-prio-map-addr=%p, "
+ "clock-class-addr=%p, clock-class-name=\"%s\", "
+ "clock-value-addr=%p",
+ inactivity_notification,
+ inactivity_notification->cc_prio_map,
+ clock_value->clock_class,
+ bt_clock_class_get_name(clock_value->clock_class), clock_value);