Skip to content

Commit

Permalink
[memory] PANIC on the off-chance that an allocator hasn't implemented…
Browse files Browse the repository at this point in the history
… all the commands
  • Loading branch information
grouse committed Feb 16, 2025
1 parent df09b6d commit 7d8ba64
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions memory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,9 @@ void* malloc_alloc(void *v_state, M_Proc cmd, const void *old_ptr, i64 old_size,
LOG_ERROR("reset called on malloc allocator, unsupported");
return nullptr;
}

PANIC("unhandled allocator procedure: %d", cmd);
return nullptr;
}

Allocator tl_linear_allocator(i64 size)
Expand Down

0 comments on commit 7d8ba64

Please sign in to comment.