--- cogl/winsys/cogl-texture-pixmap-x11.c.orig 2014-01-20 17:31:02.000000000 +0000 +++ cogl/winsys/cogl-texture-pixmap-x11.c 2016-04-12 22:21:50.512414862 +0000 @@ -414,7 +414,7 @@ tex_pixmap->shm_info.shmid = shmget (IPC_PRIVATE, dummy_image->bytes_per_line * dummy_image->height, - IPC_CREAT | 0777); + IPC_CREAT | 0600); if (tex_pixmap->shm_info.shmid == -1) goto failed_shmget; @@ -422,6 +422,8 @@ if (tex_pixmap->shm_info.shmaddr == (void *) -1) goto failed_shmat; + shmctl(tex_pixmap->shm_info.shmid, IPC_RMID, NULL); + tex_pixmap->shm_info.readOnly = False; if (XShmAttach (display, &tex_pixmap->shm_info) == 0)