util: use shm_open for in-memory files

shm_open is a POSIX function creating an in-memory file. Using it simplifies
the code and removes the dependency on XDG_RUNTIME_DIR. The only downside is
that we need to generate a random name for the shm file.
This commit is contained in:
emersion 2018-10-26 18:38:23 +02:00
parent f668e49fae
commit 346ec21c4c
No known key found for this signature in database
GPG key ID: 0FDE7BE0E88F5E48
8 changed files with 80 additions and 164 deletions

View file

@ -30,4 +30,3 @@ generic
* *WAYLAND_DISPLAY*, *_WAYLAND_DISPLAY*, *WAYLAND_SOCKET*: if set probe Wayland
backend in *wlr_backend_autocreate*
* *XCURSOR_PATH*: directory where xcursors are located
* *XDG_RUNTIME_DIR*: used to store non persistent temporary files