seed r60 - trunk/libseed



Author: racarr
Date: Sun Nov  2 10:29:22 2008
New Revision: 60
URL: http://svn.gnome.org/viewvc/seed?rev=60&view=rev

Log:
Don't set this to a JSValueNull JSValue if someone passes a null this 
for a signal closure. this being null leads to JavaScriptCore hell.


Modified:
   trunk/libseed/seed-signals.c

Modified: trunk/libseed/seed-signals.c
==============================================================================
--- trunk/libseed/seed-signals.c	(original)
+++ trunk/libseed/seed-signals.c	Sun Nov  2 10:29:22 2008
@@ -175,11 +175,13 @@
 	((SeedClosure *) closure)->function = (JSObjectRef)arguments[0];
 	((SeedClosure *)closure)->object = 
 		g_object_get_data(privates->object, "js-ref");
-	if (argumentCount == 2)
+	if (argumentCount == 2 && !JSValueIsNull(eng->context,arguments[1]))
 		((SeedClosure *)closure)->this = (JSObjectRef)arguments[1];
 	else
 		((SeedClosure *)closure)->this = 0;
 	
+
+	
 	
 	g_signal_connect_closure_by_id (privates->object,
 					privates->signal_id,



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