X-Git-Url: https://git.efficios.com/?a=blobdiff_plain;f=include%2Fbabeltrace%2Fgraph%2Fself-component-port-input-notification-iterator.h;h=45f7e194306c85d2d443aa35aa38a38723ca1d9b;hb=8c6884d908cf7a7cf2340f3384441278635d19e1;hp=d79f1bc066d5273e58b84efc9aecd1a951441699;hpb=f2b0325d1bd4bc213b08fa42828d6cc86adc6a01;p=babeltrace.git diff --git a/include/babeltrace/graph/self-component-port-input-notification-iterator.h b/include/babeltrace/graph/self-component-port-input-notification-iterator.h index d79f1bc0..45f7e194 100644 --- a/include/babeltrace/graph/self-component-port-input-notification-iterator.h +++ b/include/babeltrace/graph/self-component-port-input-notification-iterator.h @@ -61,6 +61,25 @@ bt_self_component_port_input_notification_iterator_next( struct bt_self_component_port_input_notification_iterator *iterator, bt_notification_array_const *notifs, uint64_t *count); +extern void bt_self_component_port_input_notification_iterator_get_ref( + const struct bt_self_component_port_input_notification_iterator *self_component_port_input_notification_iterator); + +extern void bt_self_component_port_input_notification_iterator_put_ref( + const struct bt_self_component_port_input_notification_iterator *self_component_port_input_notification_iterator); + +#define BT_SELF_COMPONENT_PORT_INPUT_NOTIFICATION_ITERATOR_PUT_REF_AND_RESET(_var) \ + do { \ + bt_self_component_port_input_notification_iterator_put_ref(_var); \ + (_var) = NULL; \ + } while (0) + +#define BT_SELF_COMPONENT_PORT_INPUT_NOTIFICATION_ITERATOR_MOVE_REF(_var_dst, _var_src) \ + do { \ + bt_self_component_port_input_notification_iterator_put_ref(_var_dst); \ + (_var_dst) = (_var_src); \ + (_var_src) = NULL; \ + } while (0) + #ifdef __cplusplus } #endif