Преглед изворни кода

Merge pull request #271 from Breush/267-bugfix-linux-heap-alloc-zero

Fixed heap alloc not allowing empty structs on Linux
gingerBill пре 7 година
родитељ
комит
627c91124a
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      core/os/os_linux.odin

+ 1 - 1
core/os/os_linux.odin

@@ -219,7 +219,7 @@ access :: inline proc(path: string, mask: int) -> bool {
 }
 
 heap_alloc :: proc(size: int) -> rawptr {
-	assert(size > 0);
+	assert(size >= 0);
 	return _unix_calloc(1, size);
 }