diff options
Diffstat (limited to 'assemble.c')
-rw-r--r-- | assemble.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -192,9 +192,11 @@ uint16_t handle_struct(line **ln, uint64_t address, uint16_t offset, uint8_t dbg if (member && t->type != DIR_UNION && t->type != DIR_STRUCT) { member->val = offset; } - size += member_size; if (is_struct) { + size += member_size; offset += member_size; + } else if (size < member_size) { + size = member_size; } } ismember = 0; @@ -666,7 +668,7 @@ static void print_symtree(symbol *s, int depth) { } } -static void fix_symtree(line *l) { +void fix_symtree(line *l) { symbol *s = symbols; symbol *cur_sym = NULL; symbol *sym_struct = NULL; |