diff options
Diffstat (limited to 'server/main.ha')
-rw-r--r-- | server/main.ha | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/server/main.ha b/server/main.ha index 19ecc51..31cb6dc 100644 --- a/server/main.ha +++ b/server/main.ha @@ -258,6 +258,8 @@ fn floor_div(a: i32, b: i32) i32 = { fn unload_distant_chunks(state: *server_state) void = { const n_pics = len(state.pictures); + if (n_pics == 0) return; + let should_unload = alloc([true...], n_pics); defer free(should_unload); |