lib: lib-logging.c: `Babeltrace library` -> `libbabeltrace2`
authorFrancis Deslauriers <francis.deslauriers@efficios.com>
Thu, 31 Oct 2019 17:40:07 +0000 (13:40 -0400)
committerFrancis Deslauriers <francis.deslauriers@efficios.com>
Thu, 31 Oct 2019 19:13:27 +0000 (15:13 -0400)
Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Change-Id: Ibb0de3faa3bdc30fcead46467a69d8ece5d5792f
Reviewed-on: https://review.lttng.org/c/babeltrace/+/2314
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>
Tested-by: jenkins <jenkins@lttng.org>
src/lib/lib-logging.c
src/lib/logging.h
src/lib/plugin/plugin.c
src/python-plugin-provider/python-plugin-provider.c

index 8d357e30524c811059cb41b45167a7d874cd54cf..c648e336c9c3fc4abb5a90cb83c40b8e46326042 100644 (file)
@@ -1522,7 +1522,8 @@ void bt_lib_maybe_log_and_append_cause(const char *func, const char *file,
        }
 
        status = bt_current_thread_error_append_cause_from_unknown(
-               "Babeltrace library", file, line, "%s", lib_logging_buf);
+               BT_LIB_LOG_LIBBABELTRACE2_NAME, file, line, "%s",
+               lib_logging_buf);
        if (status) {
                /*
                 * Worst case: this error cause is not appended to the
index 2598b473d93b8b2fe2fc1c4cd24e170a08c7612d..2c55f14f19f0d754ca8f7c8e45eb487d1535a5fb 100644 (file)
@@ -34,6 +34,8 @@
 
 #include "logging/log.h"
 
+#define BT_LIB_LOG_LIBBABELTRACE2_NAME "libbabeltrace2"
+
 extern
 int bt_lib_log_level;
 
index 52614fbbd00644785d54845432368479c5183559..58a2419044fc9cd1c34e37d981220fa8079e09b2 100644 (file)
@@ -621,7 +621,7 @@ int bt_plugin_create_append_all_from_dir(struct bt_plugin_set *plugin_set,
                        ": path=\"%s\", recurse=%d",
                        path, recurse);
                (void) BT_CURRENT_THREAD_ERROR_APPEND_CAUSE_FROM_UNKNOWN(
-                       "Babeltrace library",
+                       BT_LIB_LOG_LIBBABELTRACE2_NAME,
                        "Cannot open directory: path=\"%s\", recurse=%d",
                        path, recurse);
                status = BT_FUNC_STATUS_ERROR;
index c6b606564ced4e564eebdda8e0e58009defb409e..11a7482133a5f590999a85ccea71ba42236d8720 100644 (file)
@@ -82,7 +82,7 @@ void append_python_traceback_error_cause(void)
                }
 
                (void) BT_CURRENT_THREAD_ERROR_APPEND_CAUSE_FROM_UNKNOWN(
-                       "Babeltrace library", "%s", exc->str);
+                       BT_LIB_LOG_LIBBABELTRACE2_NAME, "%s", exc->str);
        }
 
 end:
This page took 0.026711 seconds and 4 git commands to generate.