From 5f307809b1d2ba2204bf073a06b4bc2fe1b205bb Mon Sep 17 00:00:00 2001 From: "Carsten Haitzler (Rasterman)" Date: Tue, 29 Mar 2016 12:09:40 +0900 Subject: [PATCH] efl - evas - sw engine - donmt free spinlock because cache always needed never free the shm pool cache spinlock as it is alwasy needed once initiialized. this likely fixes a bsd hardlock issues @fix --- src/modules/evas/engines/software_x11/evas_xlib_outbuf.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/modules/evas/engines/software_x11/evas_xlib_outbuf.c b/src/modules/evas/engines/software_x11/evas_xlib_outbuf.c index d556595acf..52dffd6a5d 100644 --- a/src/modules/evas/engines/software_x11/evas_xlib_outbuf.c +++ b/src/modules/evas/engines/software_x11/evas_xlib_outbuf.c @@ -26,6 +26,7 @@ struct _Outbuf_Region int h; }; +static Eina_Bool shmpool_initted = EINA_FALSE; static Eina_List *shmpool = NULL; static int shmsize = 0; static int shmmemlimit = 20 * 1024 * 1024; @@ -150,7 +151,11 @@ _clear_xob(int psync) void evas_software_xlib_outbuf_init(void) { - eina_spinlock_new(&shmpool_lock); + if (!shmpool_initted) + { + shmpool_initted = EINA_TRUE; + eina_spinlock_new(&shmpool_lock); + } } void @@ -192,7 +197,6 @@ evas_software_xlib_outbuf_free(Outbuf *buf) eina_array_flush(&buf->priv.onebuf_regions); free(buf); _clear_xob(0); - eina_spinlock_free(&shmpool_lock); } Outbuf *