aboutsummaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'main.c')
-rw-r--r--main.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/main.c b/main.c
index 3ddc29f..9ec04d1 100644
--- a/main.c
+++ b/main.c
@@ -82,7 +82,9 @@ int main() {
render_frame(&state);
}
- array_free(state.items);
+ if (state.items) {
+ array_free(state.items);
+ }
}
void poll_events(client_state* state) {