seed r292 - trunk/libseed
- From: racarr svn gnome org
- To: svn-commits-list gnome org
- Subject: seed r292 - trunk/libseed
- Date: Sat, 22 Nov 2008 01:08:15 +0000 (UTC)
Author: racarr
Date: Sat Nov 22 01:08:15 2008
New Revision: 292
URL: http://svn.gnome.org/viewvc/seed?rev=292&view=rev
Log:
seed_boxed_finalize. Also let WebKit tie up the finalize chain for us.
Modified:
trunk/libseed/seed-signals.c
trunk/libseed/seed-structs.c
Modified: trunk/libseed/seed-signals.c
==============================================================================
--- trunk/libseed/seed-signals.c (original)
+++ trunk/libseed/seed-signals.c Sat Nov 22 01:08:15 2008
@@ -34,6 +34,7 @@
seed_signal_finalize(JSObjectRef object)
{
signal_privates * sig_priv = JSObjectGetPrivate(object);
+
g_free(sig_priv);
}
Modified: trunk/libseed/seed-structs.c
==============================================================================
--- trunk/libseed/seed-structs.c (original)
+++ trunk/libseed/seed-structs.c Sat Nov 22 01:08:15 2008
@@ -33,10 +33,11 @@
static void seed_pointer_finalize(JSObjectRef object)
{
+
seed_struct_privates * priv =
- (seed_struct_privates *) JSObjectGetPrivate(object);
+ (seed_struct_privates *) JSObjectGetPrivate(object);
- g_free(priv);
+ g_free(priv);
}
static void seed_boxed_finalize(JSObjectRef object)
@@ -52,8 +53,6 @@
g_boxed_free(type, priv->pointer);
- g_free(priv);
-
}
JSClassDefinition seed_pointer_def = {
@@ -84,7 +83,7 @@
NULL, /* Static Values */
NULL, /* Static Functions */
NULL,
- seed_pointer_finalize,
+ NULL,
NULL, /* Has Property */
0,
NULL, /* Set Property */
@@ -130,8 +129,9 @@
JSObjectRef seed_make_pointer(gpointer pointer)
{
seed_struct_privates * priv =
- g_new0(seed_struct_privates, 1);
+ g_malloc(sizeof(seed_struct_privates));
priv->pointer = pointer;
+ priv->info = 0;
return JSObjectMake(eng->context, seed_pointer_class, priv);
}
@@ -140,7 +140,7 @@
{
JSObjectRef object;
gint i, n_methods;
- seed_struct_privates * priv = g_new0(seed_struct_privates, 1);
+ seed_struct_privates * priv = g_malloc(sizeof(seed_struct_privates));
priv->pointer = younion;
priv->info = info;
@@ -169,7 +169,7 @@
{
JSObjectRef object;
gint i, n_methods;
- seed_struct_privates * priv = g_new0(seed_struct_privates, 1);
+ seed_struct_privates * priv = g_malloc(sizeof(seed_struct_privates));
priv->info = info;
priv->pointer = boxed;
@@ -185,7 +185,7 @@
{
JSObjectRef object;
gint i, n_methods;
- seed_struct_privates * priv = g_new0(seed_struct_privates, 1);
+ seed_struct_privates * priv = g_malloc(sizeof(seed_struct_privates));
priv->info = info;
priv->pointer = strukt;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]