From fefbf4bdca1b3bada588baefec059849c268e73e Mon Sep 17 00:00:00 2001 From: Waqar Ahmed Khan Date: Sat, 11 Nov 2023 13:17:23 -0800 Subject: [PATCH] Fix WSL Crash (#1076) --- source/posix/system_info.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/posix/system_info.c b/source/posix/system_info.c index b8ebc1cc0..b5a0edc87 100644 --- a/source/posix/system_info.c +++ b/source/posix/system_info.c @@ -50,7 +50,7 @@ size_t aws_system_info_processor_count(void) { uint16_t aws_get_cpu_group_count(void) { if (g_numa_num_configured_nodes_ptr) { - return (uint16_t)g_numa_num_configured_nodes_ptr(); + return aws_max_u16(1, (uint16_t)g_numa_num_configured_nodes_ptr()); } return 1U;