[gjs] context: Fix initialization code



commit 285f100be66a9ad61ecfb66cea7bd6eb34fab619
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Mon Jan 7 20:42:33 2013 -0500

    context: Fix initialization code
    
    g_once_init_leave() takes a value, not a pointer.

 gjs/context.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)
---
diff --git a/gjs/context.c b/gjs/context.c
index 8bb2d24..79a018a 100644
--- a/gjs/context.c
+++ b/gjs/context.c
@@ -528,9 +528,8 @@ set_c_strings_are_utf8_if_needed (void)
 {
     static gsize init = 0;
     if (g_once_init_enter (&init)) {
-        gsize one = 1;
         JS_SetCStringsAreUTF8();
-        g_once_init_leave (&init, &one);
+        g_once_init_leave (&init, 1);
     }
 }
 



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