From ff272ab570f376224a96f83d2f185ad3796a9155 Mon Sep 17 00:00:00 2001 From: Vito Caputo Date: Mon, 14 Aug 2023 01:00:59 -0700 Subject: modules/compose: exclude compose from layers This was prevented before but lost in the shift to til_module_setup_full() wrappers... --- src/modules/compose/compose.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/modules/compose/compose.c b/src/modules/compose/compose.c index 15f62a4..9eb46e4 100644 --- a/src/modules/compose/compose.c +++ b/src/modules/compose/compose.c @@ -233,7 +233,11 @@ static void compose_setup_free(til_setup_t *setup) static int compose_layer_module_setup(const til_settings_t *settings, til_setting_t **res_setting, const til_setting_desc_t **res_desc, til_setup_t **res_setup) { - const char *exclusions[] = { "none", NULL }; + const char *exclusions[] = { "none", "compose" /* XXX: prevent infinite recursion */, NULL }; + + /* nested compose might be interesting, but there needs to be guards to prevent the potential infinite recursion. + * note you can still access it via the ':' override prefix + */ return til_module_setup_full(settings, res_setting, -- cgit v1.2.3