diff options
author | Kristian Høgsberg <krh@bitplanet.net> | 2011-05-02 14:48:48 -0400 |
---|---|---|
committer | Kristian Høgsberg <krh@bitplanet.net> | 2011-05-02 14:48:48 -0400 |
commit | 92d61f13b980e4ecc16724e2b0d823dd4f9a820b (patch) | |
tree | 0512f3f43add5bde8721cdbce7f458d675637876 | |
parent | 761af3ab0a86dbb2a77446270774faf5f91e3752 (diff) |
mmap shm buffers read/write
-rw-r--r-- | wayland/wayland-shm.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/wayland/wayland-shm.c b/wayland/wayland-shm.c index ccdae1c..5f46293 100644 --- a/wayland/wayland-shm.c +++ b/wayland/wayland-shm.c @@ -140,7 +140,8 @@ shm_create_buffer(struct wl_client *client, struct wl_shm *shm, return; } - data = mmap(NULL, stride * height, PROT_READ, MAP_SHARED, fd, 0); + data = mmap(NULL, stride * height, + PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); close(fd); if (data == MAP_FAILED) { |