[dconf/dconf-0.14] Add a comment for the previous commit



commit a223d9b3fb23f6103e9f270d9e71cb381b201b0d
Author: Ryan Lortie <desrt desrt ca>
Date:   Mon Nov 5 08:39:46 2012 -0500

    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 files changed, 3 insertions(+), 0 deletions(-)
---
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);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]