compositor: fix null dereference