mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-03 05:08:14 +00:00
Clean up allocator stuff into allocators.odin
This commit is contained in:
@@ -218,8 +218,8 @@ copy_file :: proc(dst_path, src_path: string) -> Error {
|
||||
src := open(src_path) or_return
|
||||
defer close(src)
|
||||
|
||||
info := fstat(src, _file_allocator()) or_return
|
||||
defer file_info_delete(info, _file_allocator())
|
||||
info := fstat(src, file_allocator()) or_return
|
||||
defer file_info_delete(info, file_allocator())
|
||||
if info.is_directory {
|
||||
return .Invalid_File
|
||||
}
|
||||
@@ -229,4 +229,4 @@ copy_file :: proc(dst_path, src_path: string) -> Error {
|
||||
|
||||
_, err := io.copy(to_writer(dst), to_reader(src))
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user