mirror of
https://github.com/odin-lang/Odin.git
synced 2026-01-06 04:57:55 +00:00
Fixed Index 0 is out of range 0..<0' when using '-default-to-nil-allocator' for Linux/OpenBSD/NetBSD.
This commit is contained in:
@@ -1100,7 +1100,7 @@ _processor_core_count :: proc() -> int {
|
||||
@(private, require_results)
|
||||
_alloc_command_line_arguments :: proc() -> []string {
|
||||
res := make([]string, len(runtime.args__))
|
||||
for arg, i in arg {
|
||||
for arg, i in res {
|
||||
res[i] = string(runtime.args__[i])
|
||||
}
|
||||
return res
|
||||
|
||||
@@ -1017,8 +1017,8 @@ _processor_core_count :: proc() -> int {
|
||||
@(private, require_results)
|
||||
_alloc_command_line_arguments :: proc() -> []string {
|
||||
res := make([]string, len(runtime.args__))
|
||||
for arg, i in runtime.args__ {
|
||||
res[i] = string(arg)
|
||||
for arg, i in res {
|
||||
res[i] = string(runtime.args__[i])
|
||||
}
|
||||
return res
|
||||
}
|
||||
|
||||
@@ -917,8 +917,8 @@ _processor_core_count :: proc() -> int {
|
||||
@(private, require_results)
|
||||
_alloc_command_line_arguments :: proc() -> []string {
|
||||
res := make([]string, len(runtime.args__))
|
||||
for arg, i in runtime.args__ {
|
||||
res[i] = string(arg)
|
||||
for arg, i in res {
|
||||
res[i] = string(runtime.args__[i])
|
||||
}
|
||||
return res
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user