From e74015680521597497c3218160a9e80081932896 Mon Sep 17 00:00:00 2001 From: Simon Marchi Date: Mon, 8 Jan 2024 15:36:24 -0500 Subject: [PATCH] Fix typos Run `typos -w` [1] on the repository, and cherry-pick the good changes. [1] https://github.com/crate-ci/typos Change-Id: I995cf7d851cd7ff40e47767ffe14c03fbd2d23bb Signed-off-by: Simon Marchi Reviewed-on: https://review.lttng.org/c/babeltrace/+/11426 Tested-by: jenkins Reviewed-by: Philippe Proulx --- configure.ac | 8 ++--- .../babeltrace2/graph/component-class-dev.h | 2 +- include/babeltrace2/graph/component-class.h | 2 +- .../graph/message-iterator-class.h | 8 ++--- include/babeltrace2/graph/message.h | 2 +- src/argpar/argpar.h | 4 +-- src/autodisc/autodisc.c | 8 ++--- .../python/bt2/bt2/message_iterator.py | 2 +- src/bindings/python/bt2/bt2/py_plugin.py | 2 +- src/bindings/python/bt2/setup.py.in | 6 ++-- src/cli/babeltrace2-cfg-cli-args-default.c | 2 +- src/common/common.h | 2 +- src/cpp-common/bt2/value.hpp | 2 +- src/ctf-writer/field-types.h | 2 +- src/ctf-writer/resolve.c | 4 +-- src/ctf-writer/stream-class.c | 2 +- src/ctf-writer/stream.c | 2 +- src/gen-version-i.sh | 4 +-- src/lib/graph/graph.h | 2 +- src/lib/graph/iterator.c | 4 +-- src/plugins/common/muxing/muxing.c | 6 ++-- src/plugins/ctf/common/msg-iter/msg-iter.cpp | 6 ++-- .../ctf/fs-sink/translate-ctf-ir-to-tsdl.cpp | 2 +- src/plugins/ctf/fs-src/fs.cpp | 2 +- src/plugins/ctf/fs-src/query.cpp | 2 +- src/plugins/ctf/lttng-live/lttng-live.cpp | 8 ++--- src/plugins/ctf/lttng-live/metadata.cpp | 4 +-- src/plugins/lttng-utils/debug-info/dwarf.h | 2 +- .../debug-info/trace-ir-data-copy.c | 2 +- .../lttng-utils/debug-info/trace-ir-mapping.c | 2 +- .../trace-ir-metadata-field-class-copy.c | 2 +- src/plugins/text/dmesg/dmesg.c | 2 +- src/plugins/text/pretty/pretty.h | 2 +- src/plugins/text/pretty/print.c | 4 +-- src/plugins/utils/trimmer/trimmer.c | 2 +- .../python-plugin-provider.c | 2 +- .../python/bt2/test_message_iterator.py | 6 ++-- tests/bitfield/test-bitfield.c | 2 +- tests/ctf-writer/ctf-writer.c | 34 +++++++++---------- .../flt.lttng-utils.debug-info/README.md | 2 +- .../flt.utils.muxer/bt_plugin_muxer_test.py | 4 +-- tests/lib/test-bt-uuid.c | 2 +- tests/lib/test-trace-ir-ref.c | 2 +- tests/plugins/src.ctf.lttng-live/test-live.sh | 2 +- tests/utils/python/testrunner.py | 2 +- tests/utils/tap-driver.sh | 2 +- tests/utils/tap/tap.h | 2 +- 47 files changed, 90 insertions(+), 90 deletions(-) diff --git a/configure.ac b/configure.ac index 03ac73b8..59d98e9c 100644 --- a/configure.ac +++ b/configure.ac @@ -110,7 +110,7 @@ AX_C___ATTRIBUTE__ AS_IF([test "x$ax_cv___attribute__" != "xyes"], [AC_MSG_ERROR([The compiler does not support __attribute__ extensions])]) -# Make sur we have pthread support +# Make sure we have pthread support AX_PTHREAD([], [AC_MSG_ERROR([Could not configure pthread support])]) # Checks for typedefs, structures, and compiler characteristics. @@ -396,9 +396,9 @@ AS_IF([test "x$BABELTRACE_DEBUG_MODE" = x1], [ ], [BABELTRACE_DEBUG_MODE=0]) -## ## -## Optionnal features selection ## -## ## +## ## +## Optional features selection ## +## ## # Python bindings # Disabled by default diff --git a/include/babeltrace2/graph/component-class-dev.h b/include/babeltrace2/graph/component-class-dev.h index d79dc6c4..7267e62f 100644 --- a/include/babeltrace2/graph/component-class-dev.h +++ b/include/babeltrace2/graph/component-class-dev.h @@ -33,7 +33,7 @@ A component class is the class of a \bt_comp: @attention This module (component class development API) offers functions to - programatically create component classes. To get the properties of + programmatically create component classes. To get the properties of an existing component class, see \ref api-comp-cls. A component class has methods. This module essentially diff --git a/include/babeltrace2/graph/component-class.h b/include/babeltrace2/graph/component-class.h index 05fd7f3c..4fe692f2 100644 --- a/include/babeltrace2/graph/component-class.h +++ b/include/babeltrace2/graph/component-class.h @@ -41,7 +41,7 @@ initialization parameters, to create many components with the There are two ways to obtain a component class: -- Create one programatically: see \ref api-comp-cls-dev. +- Create one programmatically: see \ref api-comp-cls-dev. - Borrow one from a \bt_plugin. diff --git a/include/babeltrace2/graph/message-iterator-class.h b/include/babeltrace2/graph/message-iterator-class.h index 5a409caf..82ee1f2d 100644 --- a/include/babeltrace2/graph/message-iterator-class.h +++ b/include/babeltrace2/graph/message-iterator-class.h @@ -419,21 +419,21 @@ The available message iterator class methods to implement are: this method, then the next time your \link api-msg-iter-cls-meth-next "next" method\endlink is called: - - For each "active" \bt_stream at the seeked time point, you must + - For each "active" \bt_stream at the sought time point, you must emit a \bt_sb_msg for this stream before you emit any other message for this stream. The stream beginning message must have a \ref api-msg-sb-prop-cs "default clock snapshot" which corresponds - to the seeked time point. + to the sought time point. - - For each "active" \bt_pkt at the seeked time point, you must + - For each "active" \bt_pkt at the sought time point, you must emit a \bt_pb_msg for this packet before you emit any other message for this packet. The packet beginning message must have a \ref api-msg-pb-prop-cs "default clock snapshot" which corresponds - to the seeked time point. + to the sought time point. The \bt_name project recommends that this method executes fast enough so as not to block an interactive application running on the diff --git a/include/babeltrace2/graph/message.h b/include/babeltrace2/graph/message.h index cdd125fd..a73d6e1c 100644 --- a/include/babeltrace2/graph/message.h +++ b/include/babeltrace2/graph/message.h @@ -792,7 +792,7 @@ A message iterator inactivity message has the following property:

\anchor api-msg-mip Message Interchange Protocol

The Message Interchange Protocol (MIP) is the system of rules -used by \bt_p_comp and \bt_p_msg_iter to exchance messages within a +used by \bt_p_comp and \bt_p_msg_iter to exchange messages within a trace processing graph. The MIP covers everything related to messages and what they contain, as diff --git a/src/argpar/argpar.h b/src/argpar/argpar.h index 27503c56..e34b209a 100644 --- a/src/argpar/argpar.h +++ b/src/argpar/argpar.h @@ -243,7 +243,7 @@ For example, with the following command line (all options have no argument): @code{.unparsed} --f -m meow --jus mix --kilo +-f -m meow --just mix --kilo @endcode The original argument index of \c meow is 2 while the original @@ -278,7 +278,7 @@ For example, with the following command line (all options have no argument): @code{.unparsed} --f -m meow --jus mix --kilo +-f -m meow --just mix --kilo @endcode The non-option index of \c meow is 0 while the original diff --git a/src/autodisc/autodisc.c b/src/autodisc/autodisc.c index ed822ec7..d171a33d 100644 --- a/src/autodisc/autodisc.c +++ b/src/autodisc/autodisc.c @@ -347,7 +347,7 @@ auto_source_discovery_internal_status support_info_query_all_sources( const bt_component_class_source *source; const bt_plugin *plugin; const bt_value *group; - double weigth; + double weight; } winner = { NULL, NULL, NULL, 0 }; if (interrupter && bt_interrupter_is_set(interrupter)) { @@ -479,7 +479,7 @@ auto_source_discovery_internal_status support_info_query_all_sources( bt_plugin_get_name(plugin), bt_component_class_get_name(cc), input, input_type, weight, group_value ? bt_value_string_get(group_value) : "(none)"); - if (weight > winner.weigth) { + if (weight > winner.weight) { winner.source = source_cc; winner.plugin = plugin; @@ -487,7 +487,7 @@ auto_source_discovery_internal_status support_info_query_all_sources( winner.group = group_value; bt_value_get_ref(winner.group); - winner.weigth = weight; + winner.weight = weight; } } else if (query_status == BT_QUERY_EXECUTOR_QUERY_STATUS_ERROR) { BT_AUTODISC_LOGE_APPEND_CAUSE("babeltrace.support-info query failed."); @@ -516,7 +516,7 @@ auto_source_discovery_internal_status support_info_query_all_sources( group = winner.group ? bt_value_string_get(winner.group) : NULL; BT_LOGI("Input awarded: input=%s, type=%s, component-class-name=source.%s.%s, weight=%f, group=%s", - input, input_type, plugin_name, source_name, winner.weigth, group ? group : "(none)"); + input, input_type, plugin_name, source_name, winner.weight, group ? group : "(none)"); status = auto_source_discovery_add(auto_disc, plugin_name, source_name, group, input, original_input_index, log_level); diff --git a/src/bindings/python/bt2/bt2/message_iterator.py b/src/bindings/python/bt2/bt2/message_iterator.py index b6887dc0..8703e90b 100644 --- a/src/bindings/python/bt2/bt2/message_iterator.py +++ b/src/bindings/python/bt2/bt2/message_iterator.py @@ -171,7 +171,7 @@ class _UserMessageIterator(_MessageIterator): raise bt2_utils.Stop def _bt_next_from_native(self): - # this can raise anything: it's catched by the native part + # this can raise anything: it's caught by the native part try: msg = next(self) except StopIteration: diff --git a/src/bindings/python/bt2/bt2/py_plugin.py b/src/bindings/python/bt2/bt2/py_plugin.py index 223615a5..2a7414bb 100644 --- a/src/bindings/python/bt2/bt2/py_plugin.py +++ b/src/bindings/python/bt2/bt2/py_plugin.py @@ -106,7 +106,7 @@ def _try_load_plugin_module(path): module_name = "bt_plugin_{}".format(h.hexdigest()) assert module_name not in sys.modules - # try loading the module: any raised exception is catched by the caller + # try loading the module: any raised exception is caught by the caller if sys.version_info < (3, 5): mod = importlib.machinery.SourceFileLoader(module_name, path).load_module() else: diff --git a/src/bindings/python/bt2/setup.py.in b/src/bindings/python/bt2/setup.py.in index d7eca061..cadefb72 100644 --- a/src/bindings/python/bt2/setup.py.in +++ b/src/bindings/python/bt2/setup.py.in @@ -60,12 +60,12 @@ def get_cflags(): # distutils performs a similar transformation step on LDSHARED on -# darwin to use the overriden CC as the default command for LDSHARED +# darwin to use the overridden CC as the default command for LDSHARED # (see distutils' customize_compiler() step in the sysconfig module). # # This takes it a step further by using our own LDFLAGS (when available) -# along with the overriden compiler and ensure that flags that are unsupported -# by either the Python interprter's CC or the overriden CC don't cause a +# along with the overridden compiler and ensure that flags that are unsupported +# by either the Python interprter's CC or the overridden CC don't cause a # build failure. def get_ldshared(): cc = os.environ.get("CC") diff --git a/src/cli/babeltrace2-cfg-cli-args-default.c b/src/cli/babeltrace2-cfg-cli-args-default.c index 0e657720..e8cb2e1d 100644 --- a/src/cli/babeltrace2-cfg-cli-args-default.c +++ b/src/cli/babeltrace2-cfg-cli-args-default.c @@ -42,7 +42,7 @@ enum bt_config_cli_args_status bt_config_cli_args_create_with_default(int argc, g_setenv("LIBBABELTRACE2_PLUGIN_PROVIDER_DIR", CONFIG_IN_TREE_PROVIDER_DIR, 0); #else /* - * If the Pyhton plugin provider is disabled, use a non-exitent path to avoid + * If the Python plugin provider is disabled, use a non-exitent path to avoid * loading the system installed provider if it exit, if the env variable is * already set, do not overwrite it. */ diff --git a/src/common/common.h b/src/common/common.h index bf3a8388..f546b631 100644 --- a/src/common/common.h +++ b/src/common/common.h @@ -334,7 +334,7 @@ size_t bt_common_get_page_size(int log_level); /* * Adds the digit separator `sep` as many times as needed to form groups * of `digits_per_group` digits within `str`. `str` must have enough - * room to accomodate the new separators, that is: + * room to accommodate the new separators, that is: * * strlen(str) + (strlen(str) / digits_per_group) + 1 * diff --git a/src/cpp-common/bt2/value.hpp b/src/cpp-common/bt2/value.hpp index 9b12211c..81c03367 100644 --- a/src/cpp-common/bt2/value.hpp +++ b/src/cpp-common/bt2/value.hpp @@ -1162,7 +1162,7 @@ using CommonMapValueForEachUserFunc = std::function` (the user function to call). * * This function catches any exception which the user function throws - * and returns the `ErrorStatus` value. If there's no execption, this + * and returns the `ErrorStatus` value. If there's no exception, this * function returns the `OkStatus` value. */ template diff --git a/src/ctf-writer/field-types.h b/src/ctf-writer/field-types.h index 064108ce..f5dbd99e 100644 --- a/src/ctf-writer/field-types.h +++ b/src/ctf-writer/field-types.h @@ -73,7 +73,7 @@ struct bt_ctf_field_type_common { /* * A type can't be modified once it is added to an event or after a - * a field has been instanciated from it. + * a field has been instantiated from it. */ int frozen; diff --git a/src/ctf-writer/resolve.c b/src/ctf-writer/resolve.c index 1cd24489..daa2b32b 100644 --- a/src/ctf-writer/resolve.c +++ b/src/ctf-writer/resolve.c @@ -1048,7 +1048,7 @@ int resolve_sequence_or_variant_type(struct bt_ctf_field_type_common *type, ret = bt_ctf_field_type_common_variant_set_tag_field_path( type, target_field_path); if (ret) { - BT_LOGW("Cannot set varaint field type's tag field path: " + BT_LOGW("Cannot set variant field type's tag field path: " "ret=%d, ft-addr=%p, path=\"%s\", target-field-path=\"%s\"", ret, type, pathstr, target_field_path_pretty_str); @@ -1058,7 +1058,7 @@ int resolve_sequence_or_variant_type(struct bt_ctf_field_type_common *type, ret = bt_ctf_field_type_common_variant_set_tag_field_type( type, target_type); if (ret) { - BT_LOGW("Cannot set varaint field type's tag field type: " + BT_LOGW("Cannot set variant field type's tag field type: " "ret=%d, ft-addr=%p, path=\"%s\", target-field-path=\"%s\"", ret, type, pathstr, target_field_path_pretty_str); diff --git a/src/ctf-writer/stream-class.c b/src/ctf-writer/stream-class.c index f18bbef5..1c6245de 100644 --- a/src/ctf-writer/stream-class.c +++ b/src/ctf-writer/stream-class.c @@ -917,7 +917,7 @@ int bt_ctf_stream_class_serialize(struct bt_ctf_stream_class *stream_class, * The reference to the trace is only borrowed since the * serialization of the stream class might have been triggered * by the trace's destruction. In such a case, the trace's - * reference count would, unexepectedly, go through the sequence + * reference count would, unexpectedly, go through the sequence * 1 -> 0 -> 1 -> 0 -> ..., provoking an endless loop of destruction * and serialization. */ diff --git a/src/ctf-writer/stream.c b/src/ctf-writer/stream.c index 2242d977..43150a88 100644 --- a/src/ctf-writer/stream.c +++ b/src/ctf-writer/stream.c @@ -1923,7 +1923,7 @@ end: * Returns the following codes: * 1 if the field was found and set, * 0 if nothing was done (field not found, or was already set), - * <0 if an error was encoutered + * <0 if an error was encountered */ static int try_set_structure_field_integer(struct bt_ctf_field *structure, const char *name, diff --git a/src/gen-version-i.sh b/src/gen-version-i.sh index aea19594..e0611937 100755 --- a/src/gen-version-i.sh +++ b/src/gen-version-i.sh @@ -69,7 +69,7 @@ fi # Fetch the BT_VERSION_EXTRA_DESCRIPTION define from "version/extra_version_description", # sanitize and format it with a sed script to replace all non-alpha-numeric values - # with "-" and join all lines by replacing "\n" with litteral string c-style "\n" and + # with "-" and join all lines by replacing "\n" with literal string c-style "\n" and # output it to "version.i.tmp". echo "#define BT_VERSION_EXTRA_DESCRIPTION \"$($SED -E ':a ; N ; $!ba ; s/[^a-zA-Z0-9 \n\t\.,]/-/g ; s/\r{0,1}\n/\\n/g' "$TOP_SRCDIR/version/extra_version_description" 2> /dev/null)\"" @@ -80,7 +80,7 @@ fi # The sanitize step uses sed with a script to replace all # non-alpha-numeric values, except " " (space), to "-". # The formatting step uses sed with a script to join all lines - # by replacing "\n" with litteral string c-style "\n". + # by replacing "\n" with literal string c-style "\n". # shellcheck disable=SC2012 echo "#define BT_VERSION_EXTRA_PATCHES \"$(ls -1 "$TOP_SRCDIR/version/extra_patches" | $GREP -v '^README.adoc' | $SED -E ':a ; N ; $!ba ; s/[^a-zA-Z0-9 \n\t\.]/-/g ; s/\r{0,1}\n/\\n/g' 2> /dev/null)\"" } >> common/version.i.tmp diff --git a/src/lib/graph/graph.h b/src/lib/graph/graph.h index 29490cdb..f1b39475 100644 --- a/src/lib/graph/graph.h +++ b/src/lib/graph/graph.h @@ -60,7 +60,7 @@ struct bt_graph { * * In terms of ownership: * 1) The graph is the components' parent, - * 2) The graph is the connnections' parent, + * 2) The graph is the connections' parent, * 3) Components share the ownership of their connections, * 4) A connection holds weak references to its two component endpoints. */ diff --git a/src/lib/graph/iterator.c b/src/lib/graph/iterator.c index ff9f4a45..a76e325b 100644 --- a/src/lib/graph/iterator.c +++ b/src/lib/graph/iterator.c @@ -1257,7 +1257,7 @@ bt_message_iterator_next( * by its downstream owner. * * For the same reason, there is no way that this iterator could - * have seeked (cannot seek a self message iterator). + * have sought (cannot seek a self message iterator). */ BT_ASSERT_DBG(iterator->state == BT_MESSAGE_ITERATOR_STATE_ACTIVE); @@ -2028,7 +2028,7 @@ end: /* * This function is installed as the iterator's next callback after we have - * auto-seeked (seeked to the beginning and fast-forwarded) to send the + * auto-sought (sought to the beginning and fast-forwarded) to send the * messages saved in iterator->auto_seek.msgs. Once this is done, the original * next callback is put back. */ diff --git a/src/plugins/common/muxing/muxing.c b/src/plugins/common/muxing/muxing.c index 699a43ca..e15d1f68 100644 --- a/src/plugins/common/muxing/muxing.c +++ b/src/plugins/common/muxing/muxing.c @@ -66,10 +66,10 @@ int message_type_weight(const bt_message_type msg_type) } /* - * Compare 2 messages to order them in a determinitic way based on their + * Compare 2 messages to order them in a deterministic way based on their * types. - * Returns -1 is left mesage must go first - * Returns 1 is right mesage must go first + * Returns -1 is left message must go first + * Returns 1 is right message must go first */ static int compare_messages_by_type(struct messages_to_compare *msgs) diff --git a/src/plugins/ctf/common/msg-iter/msg-iter.cpp b/src/plugins/ctf/common/msg-iter/msg-iter.cpp index 79de791c..33ad4a27 100644 --- a/src/plugins/ctf/common/msg-iter/msg-iter.cpp +++ b/src/plugins/ctf/common/msg-iter/msg-iter.cpp @@ -1791,7 +1791,7 @@ end: /* * Ensure the message iterator's `stored_values` array is large enough to - * accomodate `storing_index`. + * accommodate `storing_index`. * * We may need more slots in the array than initially allocated if more * metadata arrives along the way. @@ -2741,7 +2741,7 @@ enum ctf_msg_iter_status ctf_msg_iter_get_next_message(struct ctf_msg_iter *msg_ } goto end; case STATE_EMIT_MSG_DISCARDED_EVENTS: - /* create_msg_discared_events() logs errors */ + /* create_msg_discarded_events() logs errors */ *message = create_msg_discarded_events(msg_it); if (!*message) { @@ -2750,7 +2750,7 @@ enum ctf_msg_iter_status ctf_msg_iter_get_next_message(struct ctf_msg_iter *msg_ goto end; case STATE_EMIT_MSG_DISCARDED_PACKETS: - /* create_msg_discared_packets() logs errors */ + /* create_msg_discarded_packets() logs errors */ *message = create_msg_discarded_packets(msg_it); if (!*message) { diff --git a/src/plugins/ctf/fs-sink/translate-ctf-ir-to-tsdl.cpp b/src/plugins/ctf/fs-sink/translate-ctf-ir-to-tsdl.cpp index 85d8ccf9..db7af865 100644 --- a/src/plugins/ctf/fs-sink/translate-ctf-ir-to-tsdl.cpp +++ b/src/plugins/ctf/fs-sink/translate-ctf-ir-to-tsdl.cpp @@ -717,7 +717,7 @@ static void append_stream_class(struct ctx *ctx, struct fs_sink_ctf_stream_class } /* - * Unconditionnally write the packet sequence number as, even if + * Unconditionally write the packet sequence number as, even if * there's no possible discarded packets message, it's still * useful information to have. */ diff --git a/src/plugins/ctf/fs-src/fs.cpp b/src/plugins/ctf/fs-src/fs.cpp index 86b4c45b..5306b421 100644 --- a/src/plugins/ctf/fs-src/fs.cpp +++ b/src/plugins/ctf/fs-src/fs.cpp @@ -137,7 +137,7 @@ ctf_fs_iterator_next(bt_self_message_iterator *iterator, bt_message_array_const * accumulated message objects in the output * message array, so we need to return * BT_MESSAGE_ITERATOR_NEXT_METHOD_STATUS_OK so that they are - * transfered to downstream. This other status occurs + * transferred to downstream. This other status occurs * again the next time muxer_msg_iter_do_next() is * called, possibly without any accumulated * message, in which case we'll return it. diff --git a/src/plugins/ctf/fs-src/query.cpp b/src/plugins/ctf/fs-src/query.cpp index 0e3bdc99..fa73ab19 100644 --- a/src/plugins/ctf/fs-src/query.cpp +++ b/src/plugins/ctf/fs-src/query.cpp @@ -165,7 +165,7 @@ end: if (metadata_fp) { ret = fclose(metadata_fp); if (ret) { - BT_LOGE_ERRNO("Cannot close metatada file stream", ": path=\"%s\"", path); + BT_LOGE_ERRNO("Cannot close metadata file stream", ": path=\"%s\"", path); } } diff --git a/src/plugins/ctf/lttng-live/lttng-live.cpp b/src/plugins/ctf/lttng-live/lttng-live.cpp index 49dc148c..35cbff95 100644 --- a/src/plugins/ctf/lttng-live/lttng-live.cpp +++ b/src/plugins/ctf/lttng-live/lttng-live.cpp @@ -1109,7 +1109,7 @@ handle_late_message(struct lttng_live_msg_iter *lttng_live_msg_iter, * by this component. We CANNOT send it as is. * * The only expected scenario in which that could happen is the - * following, everything else is a bug in this component, relay deamon, + * following, everything else is a bug in this component, relay daemon, * or CTF parser. * * Expected scenario: The CTF message iterator emitted discarded @@ -1276,7 +1276,7 @@ next_stream_iterator_for_trace(struct lttng_live_msg_iter *lttng_live_msg_iter, /* * Get the timestamp in nanoseconds from origin of this - * messsage. + * message. */ live_get_msg_ts_ns(lttng_live_msg_iter, msg, lttng_live_msg_iter->last_msg_ts_ns, &curr_msg_ts_ns); @@ -1684,7 +1684,7 @@ lttng_live_msg_iter_next(bt_self_message_iterator *self_msg_it, bt_message_array /* * Insert the next message to the message batch. This will set - * stream iterator current messsage to NULL so that next time + * stream iterator current message to NULL so that next time * we fetch the next message of that stream iterator */ BT_MESSAGE_MOVE_REF(msgs[*count], youngest_stream_iter->current_msg); @@ -1704,7 +1704,7 @@ return_status: /* * If we gathered messages, return _OK even if the graph was * interrupted. This allows for the components downstream to at - * least get the thoses messages. If the graph was indeed + * least get the those messages. If the graph was indeed * interrupted there should not be another _next() call as the * application will tear down the graph. This component class * doesn't support restarting after an interruption. diff --git a/src/plugins/ctf/lttng-live/metadata.cpp b/src/plugins/ctf/lttng-live/metadata.cpp index b8fbf727..b081d639 100644 --- a/src/plugins/ctf/lttng-live/metadata.cpp +++ b/src/plugins/ctf/lttng-live/metadata.cpp @@ -212,7 +212,7 @@ enum lttng_live_iterator_status lttng_live_metadata_update(struct lttng_live_tra goto end; } - /* The relay sent zero bytes of metdata. */ + /* The relay sent zero bytes of metadata. */ trace->metadata_stream_state = LTTNG_LIVE_METADATA_STREAM_STATE_NOT_NEEDED; goto end; } @@ -263,7 +263,7 @@ enum lttng_live_iterator_status lttng_live_metadata_update(struct lttng_live_tra trace->clock_class = borrow_any_clock_class(trace->trace_class); } - /* The metadata was updated succesfully. */ + /* The metadata was updated successfully. */ trace->metadata_stream_state = LTTNG_LIVE_METADATA_STREAM_STATE_NOT_NEEDED; break; diff --git a/src/plugins/lttng-utils/debug-info/dwarf.h b/src/plugins/lttng-utils/debug-info/dwarf.h index 1482cdf2..2a446b19 100644 --- a/src/plugins/lttng-utils/debug-info/dwarf.h +++ b/src/plugins/lttng-utils/debug-info/dwarf.h @@ -196,7 +196,7 @@ int bt_dwarf_die_get_call_line(struct bt_dwarf_die *die, * @param addr The memory address to verify * @param contains Out parameter, true if addr is contained, * false if not - * @returns 0 on succes, -1 on failure + * @returns 0 on success, -1 on failure */ int bt_dwarf_die_contains_addr(struct bt_dwarf_die *die, uint64_t addr, bool *contains); diff --git a/src/plugins/lttng-utils/debug-info/trace-ir-data-copy.c b/src/plugins/lttng-utils/debug-info/trace-ir-data-copy.c index ee210269..51f76c00 100644 --- a/src/plugins/lttng-utils/debug-info/trace-ir-data-copy.c +++ b/src/plugins/lttng-utils/debug-info/trace-ir-data-copy.c @@ -71,7 +71,7 @@ enum debug_info_trace_ir_mapping_status copy_trace_content( bt_trace_borrow_environment_entry_by_index_const( in_trace, i, &value_name, &value); - BT_COMP_LOGD("Copying trace environnement entry: " + BT_COMP_LOGD("Copying trace environment entry: " "index=%" PRId64 ", value-addr=%p, value-name=\"%s\"", i, value, value_name); diff --git a/src/plugins/lttng-utils/debug-info/trace-ir-mapping.c b/src/plugins/lttng-utils/debug-info/trace-ir-mapping.c index 7ddf9f14..5c805f2d 100644 --- a/src/plugins/lttng-utils/debug-info/trace-ir-mapping.c +++ b/src/plugins/lttng-utils/debug-info/trace-ir-mapping.c @@ -40,7 +40,7 @@ bt_trace_class *create_new_mapped_trace_class(struct trace_ir_maps *ir_maps, BT_ASSERT(!metadata_maps->output_trace_class); - /* Create the ouput trace class. */ + /* Create the output trace class. */ metadata_maps->output_trace_class = bt_trace_class_create(ir_maps->self_comp); if (!metadata_maps->output_trace_class) { diff --git a/src/plugins/lttng-utils/debug-info/trace-ir-metadata-field-class-copy.c b/src/plugins/lttng-utils/debug-info/trace-ir-metadata-field-class-copy.c index 68504d2b..7dbb262c 100644 --- a/src/plugins/lttng-utils/debug-info/trace-ir-metadata-field-class-copy.c +++ b/src/plugins/lttng-utils/debug-info/trace-ir-metadata-field-class-copy.c @@ -22,7 +22,7 @@ #include "trace-ir-metadata-field-class-copy.h" /* - * This fonction walks througth the nested structures field class to resolve a + * This function walks through the nested structures field class to resolve a * field path object. A field path is made of indexes inside possibly nested * structures ultimately leading to a field class. */ diff --git a/src/plugins/text/dmesg/dmesg.c b/src/plugins/text/dmesg/dmesg.c index d23e31be..790b58d4 100644 --- a/src/plugins/text/dmesg/dmesg.c +++ b/src/plugins/text/dmesg/dmesg.c @@ -852,7 +852,7 @@ bt_message_iterator_class_next_method_status dmesg_msg_iter_next( * accumulated message objects in the output * message array, so we need to return * BT_SELF_MESSAGE_ITERATOR_STATUS_OK so that they - * are transfered to downstream. This other status + * are transferred to downstream. This other status * occurs again the next time muxer_msg_iter_do_next() * is called, possibly without any accumulated * message, in which case we'll return it. diff --git a/src/plugins/text/pretty/pretty.h b/src/plugins/text/pretty/pretty.h index d9f383b1..b73f3345 100644 --- a/src/plugins/text/pretty/pretty.h +++ b/src/plugins/text/pretty/pretty.h @@ -14,7 +14,7 @@ #include /* - * `bt_field_*_enumeration` are backed by 64 bits integers so the maximun + * `bt_field_*_enumeration` are backed by 64 bits integers so the maximum * number of bitflags in any enumeration is 64. */ #define ENUMERATION_MAX_BITFLAGS_COUNT (sizeof(uint64_t) * 8) diff --git a/src/plugins/text/pretty/print.c b/src/plugins/text/pretty/print.c index 4a2fee57..a08235e8 100644 --- a/src/plugins/text/pretty/print.c +++ b/src/plugins/text/pretty/print.c @@ -745,7 +745,7 @@ void print_enum_value_bit_flag_label_arrays(struct pretty_component *pretty) * * This function will set the count to the count of mapping labels that match * the value. If count == 0, the caller has nothing to do, if count > 0, - * the label_array contains the labels to print and the caller is reponsible + * the label_array contains the labels to print and the caller is responsible * to call g_free on it once the values have been used. */ static @@ -835,7 +835,7 @@ end: * * This function will set the count to the count of mapping labels that match * the value. If count == 0, the caller has nothing to do, if count > 0, - * the label_array contains the labels to print and the caller is reponsible + * the label_array contains the labels to print and the caller is responsible * to call g_free on it once the values have been used. */ static diff --git a/src/plugins/utils/trimmer/trimmer.c b/src/plugins/utils/trimmer/trimmer.c index 094cbe92..d13a9fef 100644 --- a/src/plugins/utils/trimmer/trimmer.c +++ b/src/plugins/utils/trimmer/trimmer.c @@ -173,7 +173,7 @@ bool compile_and_match(const char *pattern, const char *string, GMatchInfo **mat /* * g_regex_match allocates `*match_info` even if it returns * FALSE. If there's no match, we have no use for it, so free - * it immediatly and don't return it to the caller. + * it immediately and don't return it to the caller. */ g_match_info_free(*match_info); *match_info = NULL; diff --git a/src/python-plugin-provider/python-plugin-provider.c b/src/python-plugin-provider/python-plugin-provider.c index 17305dd5..4df64852 100644 --- a/src/python-plugin-provider/python-plugin-provider.c +++ b/src/python-plugin-provider/python-plugin-provider.c @@ -663,7 +663,7 @@ int bt_plugin_python_create_all_from_file(const char *path, /* * Initialize Python now. * - * This is not done in the library contructor because the + * This is not done in the library constructor because the * interpreter is somewhat slow to initialize. If you don't * have any potential Python plugins, you don't need to endure * this waiting time everytime you load the library. diff --git a/tests/bindings/python/bt2/test_message_iterator.py b/tests/bindings/python/bt2/test_message_iterator.py index e121c973..62600ac5 100644 --- a/tests/bindings/python/bt2/test_message_iterator.py +++ b/tests/bindings/python/bt2/test_message_iterator.py @@ -102,7 +102,7 @@ class UserMessageIteratorTestCase(unittest.TestCase): self.assertTrue(flt_iter_initialized) # Test that creating a message iterator from a sink component on a - # non-connected inport port raises. + # non-connected input port raises. def test_create_from_sink_component_unconnected_port_raises(self): class MySink(bt2._UserSinkComponent): def __init__(comp_self, config, params, obj): @@ -124,8 +124,8 @@ class UserMessageIteratorTestCase(unittest.TestCase): graph.run() self.assertTrue(seen) - # Test that creating a message iterator from a message iteartor on a - # non-connected inport port raises. + # Test that creating a message iterator from a message iterator on a + # non-connected input port raises. def test_create_from_message_iterator_unconnected_port_raises(self): class MyFilterIter(bt2._UserMessageIterator): def __init__(iter_self, config, port): diff --git a/tests/bitfield/test-bitfield.c b/tests/bitfield/test-bitfield.c index 017ebeb3..ea5efc72 100644 --- a/tests/bitfield/test-bitfield.c +++ b/tests/bitfield/test-bitfield.c @@ -748,7 +748,7 @@ int main(int argc, char **argv) return print_encodings(src, shift, len); } - /* Run tap-formated tests */ + /* Run tap-formatted tests */ run_test(); return exit_status(); } diff --git a/tests/ctf-writer/ctf-writer.c b/tests/ctf-writer/ctf-writer.c index 0b979ace..0e46404e 100644 --- a/tests/ctf-writer/ctf-writer.c +++ b/tests/ctf-writer/ctf-writer.c @@ -678,7 +678,7 @@ void append_complex_event(struct bt_ctf_stream_class *stream_class, bt_ctf_object_put_ref(ret_field_type); event = bt_ctf_event_create(event_class); - ok(event, "Instanciate a complex event"); + ok(event, "Instantiate a complex event"); ret_event_class = bt_ctf_event_get_class(event); ok(ret_event_class == event_class, @@ -999,19 +999,19 @@ void type_field_tests(void) bt_ctf_object_put_ref(returned_type); int_16 = bt_ctf_field_create(int_16_type); - ok(int_16, "Instanciate a signed 16-bit integer"); + ok(int_16, "Instantiate a signed 16-bit integer"); uint_12 = bt_ctf_field_create(uint_12_type); - ok(uint_12, "Instanciate an unsigned 12-bit integer"); + ok(uint_12, "Instantiate an unsigned 12-bit integer"); returned_type = bt_ctf_field_get_type(int_16); ok(returned_type == int_16_type, "bt_ctf_field_get_type returns the correct type"); - /* Can't modify types after instanciating them */ + /* Can't modify types after instantiating them */ ok(bt_ctf_field_type_integer_set_base(uint_12_type, BT_CTF_INTEGER_BASE_DECIMAL), - "Check an integer type' base can't be modified after instanciation"); + "Check an integer type' base can't be modified after instantiation"); ok(bt_ctf_field_type_integer_set_signed(uint_12_type, 0), - "Check an integer type's signedness can't be modified after instanciation"); + "Check an integer type's signedness can't be modified after instantiation"); /* Check overflows are properly tested for */ ok(bt_ctf_field_integer_signed_set_value(int_16, -32768) == 0, @@ -1027,7 +1027,7 @@ void type_field_tests(void) "Check 0 is allowed for an unsigned 12-bit integer"); string = bt_ctf_field_create(string_type); - ok(string, "Instanciate a string field"); + ok(string, "Instantiate a string field"); ok(bt_ctf_field_string_set_value(string, "A value") == 0, "Set a string's value"); @@ -1421,7 +1421,7 @@ end: } static -void test_instanciate_event_before_stream(struct bt_ctf_writer *writer, +void test_instantiate_event_before_stream(struct bt_ctf_writer *writer, struct bt_ctf_clock *clock) { int ret = 0; @@ -1513,7 +1513,7 @@ void test_instanciate_event_before_stream(struct bt_ctf_writer *writer, "bt_ctf_event_get_stream returns an event's stream after it has been appended"); end: ok(ret == 0, - "Create an event before instanciating its associated stream"); + "Create an event before instantiating its associated stream"); bt_ctf_object_put_ref(stream); bt_ctf_object_put_ref(ret_stream); bt_ctf_object_put_ref(stream_class); @@ -1697,14 +1697,14 @@ int main(int argc, char **argv) == 0, "Add version (%s) environment field to writer instance", name.version); ok(bt_ctf_writer_add_environment_field(writer, "machine", name.machine) - == 0, "Add machine (%s) environment field to writer istance", + == 0, "Add machine (%s) environment field to writer instance", name.machine); /* Define a clock and add it to the trace */ ok(!bt_ctf_clock_create("signed"), "Illegal clock name rejected"); clock = bt_ctf_clock_create(clock_name); - ok(clock, "Clock created sucessfully"); + ok(clock, "Clock created successfully"); returned_clock_name = bt_ctf_clock_get_name(clock); ok(returned_clock_name, "bt_ctf_clock_get_name returns a clock name"); ok(returned_clock_name ? strcmp(returned_clock_name, clock_name) == 0 : 0, @@ -1922,7 +1922,7 @@ int main(int argc, char **argv) ok(bt_ctf_trace_get_stream_count(trace) == 0, "bt_ctf_trace_get_stream_count() succeeds and returns the correct value (0)"); stream1 = bt_ctf_writer_create_stream(writer, stream_class); - ok(stream1, "Instanciate a stream class from writer"); + ok(stream1, "Instantiate a stream class from writer"); ok(bt_ctf_trace_get_stream_count(trace) == 1, "bt_ctf_trace_get_stream_count() succeeds and returns the correct value (1)"); stream = bt_ctf_trace_get_stream_by_index(trace, 0); @@ -1966,7 +1966,7 @@ int main(int argc, char **argv) ret = bt_ctf_field_type_structure_add_field(packet_header_type, packet_header_field_type, "should_fail"); ok(ret < 0, - "Trace packet header type can't be modified once a stream has been instanciated"); + "Trace packet header type can't be modified once a stream has been instantiated"); /* * Try to modify the packet context type after a stream has been @@ -1975,7 +1975,7 @@ int main(int argc, char **argv) ret = bt_ctf_field_type_structure_add_field(packet_context_type, packet_context_field_type, "should_fail"); ok(ret < 0, - "Packet context type can't be modified once a stream has been instanciated"); + "Packet context type can't be modified once a stream has been instantiated"); /* * Try to modify the stream event context type after a stream has been @@ -1984,9 +1984,9 @@ int main(int argc, char **argv) ret = bt_ctf_field_type_structure_add_field(stream_event_context_type, integer_type, "should_fail"); ok(ret < 0, - "Stream event context type can't be modified once a stream has been instanciated"); + "Stream event context type can't be modified once a stream has been instantiated"); - /* Should fail after instanciating a stream (frozen) */ + /* Should fail after instantiating a stream (frozen) */ ok(bt_ctf_stream_class_set_clock(stream_class, clock), "Changes to a stream class that was already instantiated fail"); @@ -2021,7 +2021,7 @@ int main(int argc, char **argv) test_clock_utils(); - test_instanciate_event_before_stream(writer, clock); + test_instantiate_event_before_stream(writer, clock); append_simple_event(stream_class, stream1, clock); diff --git a/tests/data/plugins/flt.lttng-utils.debug-info/README.md b/tests/data/plugins/flt.lttng-utils.debug-info/README.md index 177ba572..38045d16 100644 --- a/tests/data/plugins/flt.lttng-utils.debug-info/README.md +++ b/tests/data/plugins/flt.lttng-utils.debug-info/README.md @@ -99,7 +99,7 @@ steps: 5. Copy the resulting trace back into the Babeltrace repository. When running babeltrace with the `--debug-info-target-prefix` option or -`target-prefix` component paramater set to the directory containing the right +`target-prefix` component parameter set to the directory containing the right `libhello-so` file. In the example used above, the `libhello-so` file is in the `x86-64-linux-gnu/dwarf-full/` directory. In the printed trace, the `my_provider:my_first_tracepoint` events should diff --git a/tests/data/plugins/flt.utils.muxer/bt_plugin_muxer_test.py b/tests/data/plugins/flt.utils.muxer/bt_plugin_muxer_test.py index eaf2c9d9..4026433f 100644 --- a/tests/data/plugins/flt.utils.muxer/bt_plugin_muxer_test.py +++ b/tests/data/plugins/flt.utils.muxer/bt_plugin_muxer_test.py @@ -368,7 +368,7 @@ class DiffEventClassName: stream = trace.create_stream(sc, 0) # Use event class name length as timestamp so that both stream - # beginning message are not at the same time. This test is targetting + # beginning message are not at the same time. This test is targeting # event message. sb_msg = msg_iter._create_stream_beginning_message(stream, len(ec.name)) ev_msg = msg_iter._create_event_message(ec, stream, 50) @@ -405,7 +405,7 @@ class DiffEventClassId: stream = trace.create_stream(sc, 0) # Use event class id as timestamp so that both stream beginning message - # are not at the same time. This test is targetting event message. + # are not at the same time. This test is targeting event message. sb_msg = msg_iter._create_stream_beginning_message(stream, ec.id) ev_msg = msg_iter._create_event_message(ec, stream, 50) se_msg = msg_iter._create_stream_end_message(stream, iter_id * 193) diff --git a/tests/lib/test-bt-uuid.c b/tests/lib/test-bt-uuid.c index 5b0c3bed..0c881ba3 100644 --- a/tests/lib/test-bt-uuid.c +++ b/tests/lib/test-bt-uuid.c @@ -175,7 +175,7 @@ void run_test(void) int main(void) { - /* Run tap-formated tests */ + /* Run tap-formatted tests */ run_test(); return exit_status(); diff --git a/tests/lib/test-trace-ir-ref.c b/tests/lib/test-trace-ir-ref.c index 5d0bdfd9..a2351047 100644 --- a/tests/lib/test-trace-ir-ref.c +++ b/tests/lib/test-trace-ir-ref.c @@ -567,7 +567,7 @@ static void test_put_order(void) /** * The objective of this test is to implement and expand upon the scenario * described in the reference counting documentation and ensure that any node of - * the Trace, Stream Class, Event Class, Stream and Event hiearchy keeps all + * the Trace, Stream Class, Event Class, Stream and Event hierarchy keeps all * other "alive" and reachable. * * External tools (e.g. valgrind) should be used to confirm that this diff --git a/tests/plugins/src.ctf.lttng-live/test-live.sh b/tests/plugins/src.ctf.lttng-live/test-live.sh index ef30ba1d..8a7bb608 100755 --- a/tests/plugins/src.ctf.lttng-live/test-live.sh +++ b/tests/plugins/src.ctf.lttng-live/test-live.sh @@ -375,7 +375,7 @@ test_split_metadata() { test_stored_values() { # Split metadata, where the new metadata requires additional stored # value slots in CTF message iterators. - local test_text="split metadata requiring additionnal stored values" + local test_text="split metadata requiring additional stored values" local cli_args_template="-i lttng-live net://localhost:@PORT@/host/hostname/stored-values -c sink.text.details" local server_args=("$test_data_dir/stored-values.json") local expected_stdout="${test_data_dir}/stored-values.expect" diff --git a/tests/utils/python/testrunner.py b/tests/utils/python/testrunner.py index 88b96ef8..4ff52d82 100644 --- a/tests/utils/python/testrunner.py +++ b/tests/utils/python/testrunner.py @@ -31,7 +31,7 @@ if __name__ == "__main__": mut_exclu_group.add_argument( "-t", "--test-case", - help="Run a specfic test module name, test class " + help="Run a specific test module name, test class " "name, or test method name " "(e.g. test_event.EventTestCase.test_clock_value)", type=str, diff --git a/tests/utils/tap-driver.sh b/tests/utils/tap-driver.sh index 94f1c3e1..bb468806 100755 --- a/tests/utils/tap-driver.sh +++ b/tests/utils/tap-driver.sh @@ -361,7 +361,7 @@ function setup_result_obj(line) sub("^(not )?ok[ \t]*", "", line) # If the result has an explicit number, get it and strip it; otherwise, - # automatically assing the next progresive number to it. + # automatically assign the next progressive number to it. if (line ~ /^[0-9]+$/ || line ~ /^[0-9]+[^a-zA-Z0-9_]/) { match(line, "^[0-9]+") diff --git a/tests/utils/tap/tap.h b/tests/utils/tap/tap.h index 76e70230..f07c1dbb 100644 --- a/tests/utils/tap/tap.h +++ b/tests/utils/tap/tap.h @@ -10,7 +10,7 @@ extern "C" { #endif /* '## __VA_ARGS__' is a gcc'ism. C99 doesn't allow the token pasting - and requires the caller to add the final comma if they've ommitted + and requires the caller to add the final comma if they've omitted the optional arguments */ #ifdef __GNUC__ # define ok(e, test, ...) ((e) ? \ -- 2.34.1