diff --git a/plane.c b/plane.c index df7ec18..07e4bae 100644 --- a/plane.c +++ b/plane.c @@ -148,6 +148,10 @@ liftoff_plane_destroy(struct liftoff_plane *plane) { size_t i; + if (plane == NULL) { + return; + } + if (plane->layer != NULL) { plane->layer->plane = NULL; }