From 8fe63c6578c24f458ec8a4a3b3243a0d7514756a Mon Sep 17 00:00:00 2001 From: Josef 'Jeff' Sipek Date: Tue, 16 Apr 2019 18:45:21 -0400 Subject: [PATCH] lib: Move event filter test's event categories from stack to .data Event categories must not be allocated on the stack. Categories must be accessible for the duration of the program runtime. --- src/lib/test-event-filter.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/test-event-filter.c b/src/lib/test-event-filter.c index 082e57cb45..840c3c43e8 100644 --- a/src/lib/test-event-filter.c +++ b/src/lib/test-event-filter.c @@ -146,10 +146,10 @@ static void test_event_filter_inc_int(void) static void test_event_filter_parent_category_match(void) { - struct event_category parent_category = { + static struct event_category parent_category = { .name = "parent", }; - struct event_category child_category = { + static struct event_category child_category = { .parent = &parent_category, .name = "child", }; -- 2.47.3