aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteven Rostedt (Google) <rostedt@goodmis.org>2023-05-30 02:21:11 -0400
committerSteven Rostedt (Google) <rostedt@goodmis.org>2023-05-30 03:02:30 -0400
commit6332309276706889083bdc51b9a4d250d050482a (patch)
treec3a47fce52bd1206eca27d536acfabef9184a786
parent25cd2064491ee2eee8f815fc373a2ad841a6bc57 (diff)
downloadlibtracefs-6332309276706889083bdc51b9a4d250d050482a.tar.gz
libtracefs/utest: Do not use synth for test_synth element
The test_synth_compare() function is confusing as it uses "synth" for the test_synth structure. "synth" should only be used for tracefs_synth descriptors. Rename it to "sevents" to match the variable of the calling function. Link: https://lore.kernel.org/linux-trace-devel/20230530022111.25bd25de@rorschach.local.home Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
-rw-r--r--utest/tracefs-utest.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/utest/tracefs-utest.c b/utest/tracefs-utest.c
index 9cfafdb..0f40756 100644
--- a/utest/tracefs-utest.c
+++ b/utest/tracefs-utest.c
@@ -983,7 +983,7 @@ struct test_synth {
char *match_name;
};
-static void test_synth_compare(struct test_synth *synth, struct tracefs_dynevent **devents)
+static void test_synth_compare(struct test_synth *sevents, struct tracefs_dynevent **devents)
{
enum tracefs_dynevent_type stype;
char *format;
@@ -996,9 +996,9 @@ static void test_synth_compare(struct test_synth *synth, struct tracefs_dynevent
CU_TEST(stype == TRACEFS_DYNEVENT_SYNTH);
if (stype != TRACEFS_DYNEVENT_SYNTH)
continue;
- CU_TEST(event && synth[i].name && strcmp(event, synth[i].name) == 0);
- if (synth[i].match_name) {
- CU_TEST(strstr(format, synth[i].match_name) != NULL);
+ CU_TEST(event && sevents[i].name && strcmp(event, sevents[i].name) == 0);
+ if (sevents[i].match_name) {
+ CU_TEST(strstr(format, sevents[i].match_name) != NULL);
}
free(event);
free(format);