surface: don't destroy surface while compositor has locks
References: https://github.com/swaywm/wlroots/issues/2957
Breaking change: wlr_surface.resource
may now be NULL if the client has destroyed it but the compositor still has locks.
TODO: check all surface->resource
usage throughout wlroots, make sure we won't hit a NULL dereference.
Edited by Kirill Primak