mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-06 15:48:51 +00:00
os2: Resolve temp allocator collisions
This commit is contained in:
@@ -35,11 +35,11 @@ _get_executable_path :: proc(allocator: runtime.Allocator) -> (path: string, err
|
||||
return real(arg, allocator)
|
||||
}
|
||||
|
||||
TEMP_ALLOCATOR_GUARD()
|
||||
temp_allocator := get_temp_allocator(TEMP_ALLOCATOR_GUARD({ allocator }))
|
||||
|
||||
buf := strings.builder_make(temp_allocator())
|
||||
buf := strings.builder_make(temp_allocator)
|
||||
|
||||
paths := get_env("PATH", temp_allocator())
|
||||
paths := get_env("PATH", temp_allocator)
|
||||
for dir in strings.split_iterator(&paths, ":") {
|
||||
strings.builder_reset(&buf)
|
||||
strings.write_string(&buf, dir)
|
||||
|
||||
Reference in New Issue
Block a user