From e4f6f8c6de98f2f048279fbb112db9aedd729cb0 Mon Sep 17 00:00:00 2001 From: Pekka Paalanen Date: Mon, 11 Nov 2019 15:18:51 +0200 Subject: [PATCH] tests/ivi: rename test_section Use a different section name to make sure that if this plugin is loaded into the same process as where weston-test-runner.h is used, the two different sections cannot get mixed up. This is just a precaution, but it removes a bit of reader confusion as well. Signed-off-by: Pekka Paalanen --- tests/ivi-layout-test-plugin.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/ivi-layout-test-plugin.c b/tests/ivi-layout-test-plugin.c index 561f5e51..9e7bb3d9 100644 --- a/tests/ivi-layout-test-plugin.c +++ b/tests/ivi-layout-test-plugin.c @@ -53,22 +53,23 @@ struct runner_test { static void runner_func_##name(struct test_context *); \ \ const struct runner_test runner_test_##name \ - __attribute__ ((section ("test_section"))) = \ + __attribute__ ((section ("plugin_test_section"))) = \ { \ #name, runner_func_##name \ }; \ \ static void runner_func_##name(struct test_context *ctx) -extern const struct runner_test __start_test_section; -extern const struct runner_test __stop_test_section; +extern const struct runner_test __start_plugin_test_section; +extern const struct runner_test __stop_plugin_test_section; static const struct runner_test * find_runner_test(const char *name) { const struct runner_test *t; - for (t = &__start_test_section; t < &__stop_test_section; t++) { + for (t = &__start_plugin_test_section; + t < &__stop_plugin_test_section; t++) { if (strcmp(t->name, name) == 0) return t; }