[gjs] param.cpp fix jump over value initialisation



commit 5c110be57278e8ff35e2950f105667caef79b15b
Author: Tim Lunn <tim feathertop org>
Date:   Wed Sep 25 08:26:21 2013 +1000

    param.cpp fix jump over value initialisation
    
    https://bugzilla.gnome.org/show_bug.cgi?id=710878

 gi/param.cpp |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/gi/param.cpp b/gi/param.cpp
index 8197115..649b92e 100644
--- a/gi/param.cpp
+++ b/gi/param.cpp
@@ -196,6 +196,7 @@ param_new_internal(JSContext *cx,
     gchar *nick;
     gchar *blurb;
     GParamFlags flags;
+    jsval foo;
 
     if (!gjs_parse_args(cx, "GObject.ParamSpec._new_internal",
                         "!sossi", argc, argv,
@@ -392,7 +393,7 @@ param_new_internal(JSContext *cx,
 
     ret = JS_TRUE;
 
-    jsval foo = OBJECT_TO_JSVAL(gjs_param_from_g_param(cx, pspec));
+    foo = OBJECT_TO_JSVAL(gjs_param_from_g_param(cx, pspec));
 
     JS_SET_RVAL(cx, vp, foo);
  out:


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