Add runtime.DEFAULT_TEMP_ALLOCATOR_TEMP_GUARD where appropriate

This commit is contained in:
gingerBill committed 2023-02-10 16:23:33 +00:00
1 parent b427a4c8c9
commit 986cba584e
31 files changed
+201 -60

No files matched your search

+1
View File
@@ -134,6 +134,7 @@ _processor_core_count :: proc() -> int {
thread_count := 0
if !result && win32.GetLastError() == 122 && length > 0 {
runtime.DEFAULT_TEMP_ALLOCATOR_TEMP_GUARD()
processors := make([]win32.SYSTEM_LOGICAL_PROCESSOR_INFORMATION, length, context.temp_allocator)
result = win32.GetLogicalProcessorInformation(&processors[0], &length)