[Xfce4-commits] <libxfce4ui:master> Make variable a volatile for thread safety.

Nick Schermer noreply at xfce.org
Wed Feb 10 16:16:01 CET 2010


Updating branch refs/heads/master
         to 77c783a4c7e0b4ff438768467ee2b720b0c070be (commit)
       from de7eea59cdcebdc2bcfb079a6734445b67b2d04c (commit)

commit 77c783a4c7e0b4ff438768467ee2b720b0c070be
Author: Nick Schermer <nick at xfce.org>
Date:   Wed Feb 10 16:13:33 2010 +0100

    Make variable a volatile for thread safety.

 libxfce4ui/xfce-sm-client.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libxfce4ui/xfce-sm-client.c b/libxfce4ui/xfce-sm-client.c
index a137f44..98ca09d 100644
--- a/libxfce4ui/xfce-sm-client.c
+++ b/libxfce4ui/xfce-sm-client.c
@@ -855,7 +855,7 @@ xsmp_ice_io_error_handler(IceConn connection)
 static void
 xsmp_ice_init(void)
 {
-    static gsize inited = 0;
+    static volatile gsize inited = 0;
 
     if(g_once_init_enter(&inited)) {
         IceIOErrorHandler default_handler;



More information about the Xfce4-commits mailing list