Cleanup: flt.lttng-utils.debug-info: remove usage of `bt_bool` inside the component...
authorFrancis Deslauriers <francis.deslauriers@efficios.com>
Mon, 29 Jun 2020 20:27:46 +0000 (16:27 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Thu, 16 Jul 2020 22:38:19 +0000 (18:38 -0400)
Also, cleanup an extra whitespace.

Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
Change-Id: I7916ededcde363e6d3c7ae2eec417eedb7c1851a

src/plugins/lttng-utils/debug-info/debug-info.c
src/plugins/lttng-utils/debug-info/utils.c
src/plugins/lttng-utils/debug-info/utils.h

index 9f564fff772a2e2a49ed912a892b6d119ba5d8b3..aa791ddd2a21d532e34550ddc433424b55af286d 100644 (file)
@@ -906,7 +906,7 @@ void handle_event_statedump(struct debug_info_msg_iter *debug_it,
        } else if (q_event_name == debug_info->q_statedump_build_id) {
                /* Build ID info */
                handle_event_statedump_build_id(debug_info, event);
-       } else if (q_event_name == debug_info-> q_lib_unload) {
+       } else if (q_event_name == debug_info->q_lib_unload) {
                handle_event_lib_unload(debug_info, event);
        }
 
index b066ea48509891255d3ed70995dbfe584514f9ef..0042e8aab7af7cbb9d118b1185b462ee4840bced 100644 (file)
@@ -6,6 +6,7 @@
  * Babeltrace - Debug info utilities
  */
 
+#include <stdbool.h>
 #include <string.h>
 
 #include <babeltrace2/babeltrace.h>
@@ -41,19 +42,18 @@ end:
 }
 
 BT_HIDDEN
-bt_bool is_event_common_ctx_dbg_info_compatible(const bt_field_class *in_field_class,
+bool is_event_common_ctx_dbg_info_compatible(const bt_field_class *in_field_class,
                const char *debug_info_field_class_name)
 {
        const bt_field_class_structure_member *member;
        const bt_field_class *ip_fc, *vpid_fc;
-       bt_bool match = BT_FALSE;
+       bool match = false;
 
        /*
         * If the debug info field is already present in the event common
         * context. Do not try to add it.
         */
-       member =
-               bt_field_class_structure_borrow_member_by_name_const(
+       member = bt_field_class_structure_borrow_member_by_name_const(
                        in_field_class, debug_info_field_class_name);
        if (member) {
                goto end;
@@ -73,7 +73,6 @@ bt_bool is_event_common_ctx_dbg_info_compatible(const bt_field_class *in_field_c
                member);
        if (bt_field_class_get_type(ip_fc) !=
                        BT_FIELD_CLASS_TYPE_UNSIGNED_INTEGER) {
-               match = BT_FALSE;
                goto end;
        }
 
@@ -85,7 +84,6 @@ bt_bool is_event_common_ctx_dbg_info_compatible(const bt_field_class *in_field_c
 
        vpid_fc = bt_field_class_structure_member_borrow_field_class_const(
                member);
-
        if (bt_field_class_get_type(vpid_fc) !=
                        BT_FIELD_CLASS_TYPE_SIGNED_INTEGER) {
                goto end;
@@ -95,7 +93,7 @@ bt_bool is_event_common_ctx_dbg_info_compatible(const bt_field_class *in_field_c
                goto end;
        }
 
-       match = BT_TRUE;
+       match = true;
 
 end:
        return match;
index 40ba38ec9170a841553386a368b5714d16006caf..c9000e9d2d18f5d249050969f721b022aad66efe 100644 (file)
@@ -9,6 +9,8 @@
 #ifndef BABELTRACE_PLUGIN_DEBUG_INFO_UTILS_H
 #define BABELTRACE_PLUGIN_DEBUG_INFO_UTILS_H
 
+#include <stdbool.h>
+
 #include <babeltrace2/babeltrace.h>
 
 #include "common/macros.h"
@@ -21,7 +23,7 @@ BT_HIDDEN
 const char *get_filename_from_path(const char *path);
 
 BT_HIDDEN
-bt_bool is_event_common_ctx_dbg_info_compatible(
+bool is_event_common_ctx_dbg_info_compatible(
                const bt_field_class *in_field_class,
                const char *debug_info_field_class_name);
 
This page took 0.02667 seconds and 4 git commands to generate.