mirror of
https://github.com/odin-lang/Odin.git
synced 2026-01-01 19:02:13 +00:00
fix odin report macos version reporting unknown when release isn't a 3 point
This commit is contained in:
@@ -532,9 +532,9 @@ gb_internal void report_os_info() {
|
||||
return;
|
||||
}
|
||||
|
||||
uint32_t major, minor, patch;
|
||||
uint32_t major, minor, patch = 0;
|
||||
|
||||
if (sscanf(cast(const char *)sw_vers, "%u.%u.%u", &major, &minor, &patch) != 3) {
|
||||
if (sscanf(cast(const char *)sw_vers, "%u.%u.%u", &major, &minor, &patch) < 1) {
|
||||
gb_printf("macOS Unknown\n");
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user