Files
stk/include/stk.h
T
anth64 38469a358f Replace dynamic allocations with fixed-size buffers and add module extension filtering
- Use fixed STK_PATH_MAX and STK_MOD_ID_BUFFER throughout for predictable memory
- Filter by platform-specific extensions (.so/.dll/.dylib) with compile-time length
- Add RELOAD event detection and is_module_loaded() helper
- Maintain feature parity across all platforms
2026-01-17 19:52:42 +01:00

32 lines
479 B
C

#ifndef STK_H
#define STK_H
#include "stk_version.h"
#include <stdlib.h>
#define STK_MOD_DIR_BUFFER 256
#define STK_MOD_ID_BUFFER 64
#define STK_PATH_MAX 256
#define STK_PATH_MAX_OS 4096
#ifdef __cplusplus
extern "C" {
#endif
typedef enum {
STK_MOD_LOAD,
STK_MOD_UNLOAD,
STK_MOD_RELOAD
} stk_module_event_t;
int stk_init(const char *mod_dir);
void stk_shutdown(void);
size_t stk_module_count(void);
size_t stk_poll(void);
#ifdef __cplusplus
}
#endif
#endif /* STK_H */