From bbe86236d2f8c0a82af42da23399890f2bd25e23 Mon Sep 17 00:00:00 2001 From: Ryan Lortie Date: Mon, 5 Nov 2012 08:39:46 -0500 Subject: Add a comment for the previous commit Provide a link to the bug with a justification for the unusual code. --- shm/dconf-shm.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'shm') diff --git a/shm/dconf-shm.c b/shm/dconf-shm.c index e47e377..d291305 100644 --- a/shm/dconf-shm.c +++ b/shm/dconf-shm.c @@ -133,6 +133,9 @@ dconf_shm_flag (const gchar *name) * don't sync up their filesystem cache with mmap()ed regions. * * Using mmap() works everywhere. + * + * See https://bugzilla.gnome.org/show_bug.cgi?id=687334 about + * why we need to have PROT_READ even though we only write. */ shm = mmap (NULL, 1, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); g_assert (shm != MAP_FAILED); -- cgit v1.2.1