feat: make module paths and entry points configurable
* Added functions to set mod dir, temp dir name, and module init/shutdown function names. * Replaced hardcoded string literals with configurable static buffers in module.c. * Improved string safety by replacing sprintf with strncpy/strncat. * Updated stk_init local path buffers to handle maximum combined path lengths.
This commit is contained in:
@@ -37,6 +37,10 @@ int stk_init(void);
|
||||
void stk_shutdown(void);
|
||||
size_t stk_module_count(void);
|
||||
size_t stk_poll(void);
|
||||
void stk_set_mod_dir(const char *path);
|
||||
void stk_set_tmp_dir_name(const char *name);
|
||||
void stk_set_module_init_fn(const char *name);
|
||||
void stk_set_module_shutdown_fn(const char *name);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user