diff options
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -1,9 +1,15 @@ #include <stdio.h> #include "config.h" +#include "regexset.h" int main(int argc, char **argv) { + /* Regex sets must be initialized before config. */ + rs_init(); if(!cfg_init()) { + /* Free any registered regex sets when config fails. + Config will fail if a regex set fails to compile all parts. */ + rs_free(); return 1; } return 0; |