Cleanup the buffers from the list once destroyed

Since we dispatch the wayland queue in destroyBuffer() a wl_buffer.release
event may come while we're still mid-through deleting all the buffers.
When getting a release event we go through the list of the buffers, and so
we risk of accessing a deleted buffer object. To fix this remove the deleted
buffers from the list as soon as possible.
Merge pull request #235 from giucam/master

Cleanup the buffers from the list once destroyed