get rid of X locks, there were missing glock/gunlock here and there

This commit is contained in:
Cedric Roux
2016-05-01 14:06:20 +02:00
parent 9463903d3a
commit 6ffa65f1d2
5 changed files with 21 additions and 27 deletions
+5 -2
View File
@@ -12,8 +12,6 @@ gui *gui_init(void)
{
struct gui *ret;
x_init_threading();
ret = calloc(1, sizeof(struct gui));
if (ret == NULL) OOM;
@@ -25,7 +23,12 @@ gui *gui_init(void)
if (pipe(ret->event_pipe))
ERR("%s\n", strerror(errno));
/* lock not necessary but there for consistency (when instrumenting x.c
* we need the gui to be locked when calling any function in x.c)
*/
glock(ret);
ret->x = x_open();
gunlock(ret);
return ret;
}