diff options
| author | Jeroen van Rijn <Kelimion@users.noreply.github.com> | 2026-02-08 12:54:20 +0100 |
|---|---|---|
| committer | Jeroen van Rijn <Kelimion@users.noreply.github.com> | 2026-02-08 12:54:20 +0100 |
| commit | 2f587767453eb486df7395be93554e9b5029be4c (patch) | |
| tree | f7acb75efd2a38c5f14fe6aecd9e01e6e46b7a3d | |
| parent | 691dc44719700add54f1ec86fbed9f9a93183855 (diff) | |
More conflicts during rebase
| -rw-r--r-- | core/time/timezone/tz_unix.odin | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/time/timezone/tz_unix.odin b/core/time/timezone/tz_unix.odin index e4121266d..ac6a4bb50 100644 --- a/core/time/timezone/tz_unix.odin +++ b/core/time/timezone/tz_unix.odin @@ -37,10 +37,11 @@ local_tz_name :: proc(allocator := context.allocator) -> (name: string, success: // Looking for tz path (ex fmt: "UTC", "Etc/UTC" or "America/Los_Angeles") path_dir, path_file := filepath.split(path) + if path_dir == "" { return } - upper_path_dir, upper_path_chunk := filepath.split(path_dir[:len(path_dir)-1]) + upper_path_dir, upper_path_chunk := filepath.split(path_dir[:len(path_dir)]) if upper_path_dir == "" { return } @@ -79,7 +80,6 @@ _region_load :: proc(_reg_str: string, allocator := context.allocator) -> (out_r delete(local_name, allocator) return nil, true } - reg_str = local_name } defer if _reg_str == "local" { delete(reg_str, allocator) } @@ -90,7 +90,7 @@ _region_load :: proc(_reg_str: string, allocator := context.allocator) -> (out_r if tzdir_ok { region_path := filepath.join({tzdir_str, reg_str}, allocator) defer delete(region_path, allocator) - + if tz_reg, ok := load_tzif_file(region_path, reg_str, allocator); ok { return tz_reg, true } |