From 0ff948af3d65150f44c9fe801ada806ce0637fe1 Mon Sep 17 00:00:00 2001 From: Freya Murphy Date: Mon, 9 Sep 2024 20:48:08 -0400 Subject: relocation table hell --- masm/reftbl.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'masm/reftbl.c') diff --git a/masm/reftbl.c b/masm/reftbl.c index bdd1f07..198af83 100644 --- a/masm/reftbl.c +++ b/masm/reftbl.c @@ -12,13 +12,13 @@ int reftbl_init(struct reference_table *ref_tbl) { ref_tbl->len = RELTBL_INIT_LEN; ref_tbl->count = 0; - ref_tbl->references = malloc(sizeof(struct reference) * + ref_tbl->references = malloc(sizeof(struct reference) * RELTBL_INIT_LEN); - if (ref_tbl->references == NULL) { - ERROR("cannot alloc"); - return M_ERROR; - } + if (ref_tbl->references == NULL) { + ERROR("cannot alloc"); + return M_ERROR; + } return M_SUCCESS; } -- cgit v1.2.3-freya