lib: use BT_LIB_LOG*_APPEND_CAUSE() where appropriate
[babeltrace.git] / src / lib / graph / message / event.c
index 8468186c24546ef3531d0e36faa98126dd576cb8..95b39605ca30bb74880815da5e0a7a20fbb8ed29 100644 (file)
  */
 
 #define BT_LOG_TAG "LIB/MSG-EVENT"
-#include "lib/lib-logging.h"
+#include "lib/logging.h"
 
 #include "common/assert.h"
 #include "lib/assert-pre.h"
+#include "lib/assert-post.h"
 #include "compat/compiler.h"
 #include "lib/object.h"
 #include <babeltrace2/trace-ir/event.h>
@@ -61,7 +62,8 @@ struct bt_message *bt_message_event_new(
 
        message = g_new0(struct bt_message_event, 1);
        if (!message) {
-               BT_LOGE_STR("Failed to allocate one event message.");
+               BT_LIB_LOGE_APPEND_CAUSE(
+                       "Failed to allocate one event message.");
                goto error;
        }
 
@@ -109,7 +111,8 @@ struct bt_message *create_event_message(
        BT_LIB_LOGD("Creating event message object: %![ec-]+E", event_class);
        event = bt_event_create(event_class, packet);
        if (G_UNLIKELY(!event)) {
-               BT_LIB_LOGE("Cannot create event from event class: "
+               BT_LIB_LOGE_APPEND_CAUSE(
+                       "Cannot create event from event class: "
                        "%![ec-]+E", event_class);
                goto error;
        }
This page took 0.023978 seconds and 4 git commands to generate.