waylandsink: take into account the case where a pool may be destroyed together with...
authorGeorge Kiagiadakis <george.kiagiadakis@collabora.com>
Wed, 2 Jul 2014 10:29:55 +0000 (13:29 +0300)
committerGeorge Kiagiadakis <george.kiagiadakis@collabora.com>
Sat, 11 Oct 2014 12:57:14 +0000 (14:57 +0200)
commit3058fe8d98d975e9199b694f383ed9c93cb71aa0
treead3e0454bff0b13f611eb601ae0cab9ea1dcdf97
parent5b1c5dbf995cefa2f090522b802c3a24d639e7de
waylandsink: take into account the case where a pool may be destroyed together with GstWlDisplay

There are two cases covered here:
1) The GstWlDisplay forces the release of the last buffer and the pool
   gets destroyed in this context, which means it unregisters all the
   other buffers from the GstWlDisplay as well and the display->buffers
   hash table gets corrupted because it is iterating.
2) The pool and its buffers get destroyed concurrently from another
   thread while GstWlDisplay is finalizing and many things get corrupted.
ext/wayland/wlbuffer.c
ext/wayland/wldisplay.c
ext/wayland/wldisplay.h