summaryrefslogtreecommitdiff
path: root/core/state.c
diff options
context:
space:
mode:
authorIan Moffett <ian@mirocom.org>2026-05-23 21:50:43 -0400
committerIan Moffett <ian@mirocom.org>2026-05-23 21:56:24 -0400
commit85c21a81bb07b8871e66fa80d377b330ab5104f1 (patch)
tree0115e4cc77883d47e1bd9d1747f25f3968cbe3ce /core/state.c
parent5c3c78f561f50401d26229bd3ed2546558f9e305 (diff)
core: symbol: Add symbol management
Signed-off-by: Ian Moffett <ian@mirocom.org>
Diffstat (limited to 'core/state.c')
-rw-r--r--core/state.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/core/state.c b/core/state.c
index f6ed48e..b64271c 100644
--- a/core/state.c
+++ b/core/state.c
@@ -35,6 +35,11 @@ state_init(struct cescal_state *state, const char *pathname)
return -1;
}
+ if (symbol_table_init(&state->symtab) < 0) {
+ close(state->in_fd);
+ return -1;
+ }
+
if (ptrbox_init(&state->ptrbox) < 0) {
close(state->in_fd);
return -1;
@@ -50,4 +55,5 @@ state_close(struct cescal_state *state)
state->in_fd = -1;
ptrbox_destroy(&state->ptrbox);
tokbuf_destroy(&state->tokbuf);
+ symbol_table_destroy(&state->symtab);
}