window: avoid a gcc warning in buffer release handler
window: avoid a gcc warning in buffer release handler

Apparently some compilers complain about set but not used variables
'available' and 'bufs', but I don't get the warning. Still, separate the
debugging code from shm_surface_buffer_release(), so that we only
compute 'bufs' when it is printed. This should fix the warnings.

The debugging code now prints the shm_surface buffer state before and
after, instead of just after.

Signed-off-by: Pekka Paalanen <0f6ae7001e34c37b02fb2c1c2573ddf8f442136a@collabora.co.uk>

eyolfson/weston,Fantu/compositor-spice,udoprog/weston,jonnylamb/weston,Gnurou/weston,mchalupa/weston,Fantu/compositor-spice,eyolfson/weston,udoprog/weston,giucam/weston,xorgy/weston,jonnylamb/weston,Tarnyko/weston-xdg_surface_present,kwm81/weston,xorgy/weston,sir-murray/weston,Gnurou/weston,Tarnyko/weston-xdg_surface_present,sir-murray/weston,kwm81/weston,mchalupa/weston,giucam/weston,Fantu/compositor-spice,krezovic/weston,krezovic/weston