*/
#define BT_LOG_TAG "CTF-WRITER-FIELD-PATH"
-#include <babeltrace/lib-logging-internal.h>
+#include <babeltrace2/lib-logging-internal.h>
-#include <babeltrace/assert-internal.h>
-#include <babeltrace/ctf-writer/field-path-internal.h>
-#include <babeltrace/ctf-writer/field-types-internal.h>
-#include <babeltrace/ctf-writer/field-types.h>
+#include <babeltrace2/assert-internal.h>
+#include <babeltrace2/ctf-writer/field-path-internal.h>
+#include <babeltrace2/ctf-writer/field-types-internal.h>
+#include <babeltrace2/ctf-writer/field-types.h>
#include <glib.h>
#include <inttypes.h>
#include <limits.h>
#include <stdint.h>
static
-void field_path_destroy(struct bt_object *obj)
+void field_path_destroy(struct bt_ctf_object *obj)
{
struct bt_ctf_field_path *field_path = (struct bt_ctf_field_path *) obj;
goto error;
}
- bt_object_init_shared(&field_path->base, field_path_destroy);
+ bt_ctf_object_init_shared(&field_path->base, field_path_destroy);
field_path->root = BT_CTF_SCOPE_UNKNOWN;
field_path->indexes = g_array_new(TRUE, FALSE, sizeof(int));
if (!field_path->indexes) {
return field_path;
error:
- BT_PUT(field_path);
+ BT_CTF_OBJECT_PUT_REF_AND_RESET(field_path);
return NULL;
}