-
-
Notifications
You must be signed in to change notification settings - Fork 313
Open
Description
This is minor but it might be nice to fix the address sanitizer output that look like this:
runtime error: member access within misaligned address 0x000112e73f44 for type 'mu_Command', which requires 8 byte alignment
Thankfully this seems really to fix:
- Add an
expect(size % 8 == 0)
at the top ofmu_push_command
- Add 4 bytes of padding to
mu_RectCommand
- Change
mu_draw_text
to do:
int aligned_size = len + 8 - (len % 8);
cmd = mu_push_command(ctx, MU_COMMAND_TEXT, sizeof(mu_TextCommand) + aligned_size);
Metadata
Metadata
Assignees
Labels
No labels