X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=src%2Fbin%2Flttng-sessiond%2Fust-field-utils.hpp;fp=src%2Fbin%2Flttng-sessiond%2Fust-field-utils.hpp;h=886ae5232137733c96d73f7b37f0811f6b423a3a;hb=7532fa3bd22e403958f46cd35c824f490d93292d;hp=0000000000000000000000000000000000000000;hpb=985aea182b618c85c51651f224abedfe367c75ee;p=lttng-tools.git diff --git a/src/bin/lttng-sessiond/ust-field-utils.hpp b/src/bin/lttng-sessiond/ust-field-utils.hpp new file mode 100644 index 000000000..886ae5232 --- /dev/null +++ b/src/bin/lttng-sessiond/ust-field-utils.hpp @@ -0,0 +1,29 @@ +/* + * Copyright (C) 2018 Francis Deslauriers francis.deslauriers@efficios.com> + * + * SPDX-License-Identifier: GPL-2.0-only + * + */ + +#ifndef LTTNG_UST_FIELD_UTILS_H +#define LTTNG_UST_FIELD_UTILS_H + +#include "lttng-ust-ctl.hpp" + +/* + * Compare two UST fields. + * Return 1 if both fields have identical definition, 0 otherwise. + */ +int match_lttng_ust_ctl_field(const struct lttng_ust_ctl_field *first, + const struct lttng_ust_ctl_field *second); + +/* + * Compare two arrays of UST fields. + * Return true if both arrays have identical field definitions, false otherwise. + */ +bool match_lttng_ust_ctl_field_array(const struct lttng_ust_ctl_field *first, + size_t nr_first, + const struct lttng_ust_ctl_field *second, + size_t nr_second); + +#endif /* LTTNG_UST_FIELD_UTILS_H */