diff options
-rw-r--r-- | src/setup.c | 2 | ||||
-rw-r--r-- | src/til.c | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/src/setup.c b/src/setup.c index 30a5401..d2618ad 100644 --- a/src/setup.c +++ b/src/setup.c @@ -22,6 +22,8 @@ int setup_interactively(til_settings_t *settings, int (*setup_func)(const til_se /* TODO: regex and error handling */ while ((r = setup_func(settings, &setting, &desc, res_setup)) > 0) { + assert(desc); + additions++; /* if setup_func() has returned a description for an undescribed preexisting setting, @@ -348,6 +348,8 @@ int til_module_randomize_setup(const til_module_t *module, unsigned seed, til_se return -ENOMEM; for (setting = NULL; module->setup(settings, &setting, &desc, res_setup) > 0; setting = NULL) { + assert(desc); + if (!setting) { if (desc->spec.random) { char *value; |