diff options
| author | Laytan Laats <laytanlaats@hotmail.com> | 2023-12-15 23:42:59 +0100 |
|---|---|---|
| committer | Laytan Laats <laytanlaats@hotmail.com> | 2023-12-15 23:43:35 +0100 |
| commit | ea709451e82ff5d963d8b6c6b6099a1789d01893 (patch) | |
| tree | 0e103e9c886abafe294406de00924c37d17e32f1 | |
| parent | d47a403d298c22cb859277593390471752835869 (diff) | |
log allocator: use %m to format size
| -rw-r--r-- | core/log/log_allocator.odin | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/core/log/log_allocator.odin b/core/log/log_allocator.odin index 934f0d643..0608f6f92 100644 --- a/core/log/log_allocator.odin +++ b/core/log/log_allocator.odin @@ -39,14 +39,14 @@ log_allocator_proc :: proc(allocator_data: rawptr, mode: runtime.Allocator_Mode, case .Alloc: logf( la.level, - "%s%s>>> ALLOCATOR(mode=.Alloc, size=%d, alignment=%d)", + "%s%s>>> ALLOCATOR(mode=.Alloc, size=%m, alignment=%d)", la.prefix, padding, size, alignment, location = location, ) case .Alloc_Non_Zeroed: logf( la.level, - "%s%s>>> ALLOCATOR(mode=.Alloc_Non_Zeroed, size=%d, alignment=%d)", + "%s%s>>> ALLOCATOR(mode=.Alloc_Non_Zeroed, size=%m, alignment=%d)", la.prefix, padding, size, alignment, location = location, ) @@ -54,7 +54,7 @@ log_allocator_proc :: proc(allocator_data: rawptr, mode: runtime.Allocator_Mode, if old_size != 0 { logf( la.level, - "%s%s<<< ALLOCATOR(mode=.Free, ptr=%p, size=%d)", + "%s%s<<< ALLOCATOR(mode=.Free, ptr=%p, size=%m)", la.prefix, padding, old_memory, old_size, location = location, ) @@ -76,7 +76,7 @@ log_allocator_proc :: proc(allocator_data: rawptr, mode: runtime.Allocator_Mode, case .Resize: logf( la.level, - "%s%s>>> ALLOCATOR(mode=.Resize, ptr=%p, old_size=%d, size=%d, alignment=%d)", + "%s%s>>> ALLOCATOR(mode=.Resize, ptr=%p, old_size=%m, size=%m, alignment=%d)", la.prefix, padding, old_memory, old_size, size, alignment, location = location, ) @@ -111,4 +111,4 @@ log_allocator_proc :: proc(allocator_data: rawptr, mode: runtime.Allocator_Mode, } } return data, err -}
\ No newline at end of file +} |