From 6c718dfa6ef5c5d3cc1e28c88adf85e26e508632 Mon Sep 17 00:00:00 2001 From: Sean McBride Date: Tue, 18 Aug 2020 10:47:46 -0400 Subject: [PATCH] chore: Stop adding to unused database --- runtime/include/module_database.h | 6 ------ runtime/src/module.c | 3 --- 2 files changed, 9 deletions(-) diff --git a/runtime/include/module_database.h b/runtime/include/module_database.h index 0b4556d..763f04a 100644 --- a/runtime/include/module_database.h +++ b/runtime/include/module_database.h @@ -17,12 +17,6 @@ extern int module_database_free_offset; static inline int module_database_add(struct module *module) { - /* - * Assumption: Module is added to database before being listened to - * TODO: Why does this matter? - */ - assert(module->socket_descriptor == -1); - int rc; if (module_database_free_offset >= MODULE_MAX_MODULE_COUNT) goto err_no_space; diff --git a/runtime/src/module.c b/runtime/src/module.c index 3c91f93..8d7a7aa 100644 --- a/runtime/src/module.c +++ b/runtime/src/module.c @@ -217,9 +217,6 @@ module_new(char *name, char *path, int32_t argument_count, uint32_t stack_size, module_initialize_table(module); local_sandbox_context_cache.module_indirect_table = NULL; - /* Add the module to the in-memory module DB */ - module_database_add(module); - /* Initialize Perf Window */ perf_window_initialize(&module->perf_window);