seahorse r2419 - in trunk: . gkr libseahorse pgp pkcs11 ssh



Author: nnielsen
Date: Sun Aug 31 19:29:01 2008
New Revision: 2419
URL: http://svn.gnome.org/viewvc/seahorse?rev=2419&view=rev

Log:
	* configure.in:
	* pkcs11/gp11.vapi:
	* pkcs11/gp11-hacks.h: (added)
	* pkcs11/seahorse-pkcs11-certificate.vala:
	* pkcs11/seahorse-key-manager-store.c: Bump vala dependency, and make 
	build work with latest vala again.
	

Added:
   trunk/pkcs11/gp11-hacks.h
Modified:
   trunk/ChangeLog
   trunk/configure.in
   trunk/gkr/vala-build.stamp
   trunk/libseahorse/vala-build.stamp
   trunk/pgp/vala-build.stamp
   trunk/pkcs11/gp11.vapi
   trunk/pkcs11/seahorse-pkcs11-certificate.c
   trunk/pkcs11/seahorse-pkcs11-certificate.h
   trunk/pkcs11/seahorse-pkcs11-certificate.vala
   trunk/pkcs11/seahorse-pkcs11-source.c
   trunk/pkcs11/seahorse-pkcs11-source.h
   trunk/pkcs11/seahorse-pkcs11.c
   trunk/pkcs11/seahorse-pkcs11.h
   trunk/pkcs11/vala-build.stamp
   trunk/ssh/vala-build.stamp

Modified: trunk/configure.in
==============================================================================
--- trunk/configure.in	(original)
+++ trunk/configure.in	Sun Aug 31 19:29:01 2008
@@ -33,7 +33,7 @@
 AM_GCONF_SOURCE_2
 GNOME_DOC_INIT
 
-VALA_PROG_VALAC([0.3.4])
+VALA_PROG_VALAC([0.3.5])
 AM_CONDITIONAL(WITH_VALA, test -n "$VALAC")
 
 dnl Get the off_t size right

Modified: trunk/gkr/vala-build.stamp
==============================================================================
--- trunk/gkr/vala-build.stamp	(original)
+++ trunk/gkr/vala-build.stamp	Sun Aug 31 19:29:01 2008
@@ -1 +1 @@
-1219784806
+1220209490

Modified: trunk/libseahorse/vala-build.stamp
==============================================================================
--- trunk/libseahorse/vala-build.stamp	(original)
+++ trunk/libseahorse/vala-build.stamp	Sun Aug 31 19:29:01 2008
@@ -1 +1 @@
-1219784761
+1220209435

Modified: trunk/pgp/vala-build.stamp
==============================================================================
--- trunk/pgp/vala-build.stamp	(original)
+++ trunk/pgp/vala-build.stamp	Sun Aug 31 19:29:01 2008
@@ -1 +1 @@
-1219784820
+1220209523

Added: trunk/pkcs11/gp11-hacks.h
==============================================================================
--- (empty file)
+++ trunk/pkcs11/gp11-hacks.h	Sun Aug 31 19:29:01 2008
@@ -0,0 +1,7 @@
+#ifndef GP11HACKS_H_
+#define GP11HACKS_H_
+
+/* TODO: Work around for deficiencies in vala 0.3.5 */
+#define GP11_IS_ATTRIBUTES(boxed)            (TRUE)
+
+#endif /* GP11HACKS_H_ */

Modified: trunk/pkcs11/gp11.vapi
==============================================================================
--- trunk/pkcs11/gp11.vapi	(original)
+++ trunk/pkcs11/gp11.vapi	Sun Aug 31 19:29:01 2008
@@ -2,7 +2,7 @@
  * These bindings will move into gnome-keyring once vala is more accepted in 
  * the desktop.
  */ 
-[CCode (cheader_filename = "gp11.h", cprefix = "GP11", lower_case_cprefix = "gp11_")]
+[CCode (cheader_filename = "gp11.h,gp11-hacks.h", cprefix = "GP11", lower_case_cprefix = "gp11_")]
 namespace GP11 {
 
 	public weak string message_from_rv (uint rv);

Modified: trunk/pkcs11/seahorse-pkcs11-certificate.c
==============================================================================
--- trunk/pkcs11/seahorse-pkcs11-certificate.c	(original)
+++ trunk/pkcs11/seahorse-pkcs11-certificate.c	Sun Aug 31 19:29:01 2008
@@ -38,14 +38,14 @@
 };
 static void seahorse_pkcs11_certificate_rebuild (SeahorsePkcs11Certificate* self);
 static gpointer seahorse_pkcs11_certificate_parent_class = NULL;
-static void seahorse_pkcs11_certificate_dispose (GObject * obj);
+static void seahorse_pkcs11_certificate_finalize (GObject * obj);
 
 
 
 SeahorsePkcs11Certificate* seahorse_pkcs11_certificate_new (GP11Object* object, GP11Attributes* attributes) {
 	SeahorsePkcs11Certificate * self;
 	g_return_val_if_fail (GP11_IS_OBJECT (object), NULL);
-	g_return_val_if_fail (attributes != NULL, NULL);
+	g_return_val_if_fail (GP11_IS_ATTRIBUTES (attributes), NULL);
 	self = g_object_newv (SEAHORSE_PKCS11_TYPE_CERTIFICATE, 0, NULL);
 	seahorse_pkcs11_certificate_set_pkcs11_object (self, object);
 	seahorse_pkcs11_certificate_set_pkcs11_attributes (self, attributes);
@@ -110,9 +110,10 @@
 }
 
 
-static char* seahorse_pkcs11_certificate_real_get_display_name (SeahorsePkcs11Certificate* self) {
+static char* seahorse_pkcs11_certificate_real_get_display_name (SeahorseObject* base) {
+	SeahorsePkcs11Certificate* self;
 	const char* _tmp4;
-	g_return_val_if_fail (SEAHORSE_PKCS11_IS_CERTIFICATE (self), NULL);
+	self = SEAHORSE_PKCS11_CERTIFICATE (base);
 	if (self->priv->_pkcs11_attributes != NULL) {
 		char* label;
 		char* _tmp2;
@@ -122,7 +123,9 @@
 		_tmp2 = NULL;
 		_tmp0 = NULL;
 		if ((_tmp1 = gp11_attributes_find_string (self->priv->_pkcs11_attributes, CKA_LABEL, &_tmp0), label = (_tmp2 = _tmp0, (label = (g_free (label), NULL)), _tmp2), _tmp1)) {
-			return label;
+			if (label != NULL) {
+				return label;
+			}
 		}
 		label = (g_free (label), NULL);
 	}
@@ -149,8 +152,9 @@
 }
 
 
-static char* seahorse_pkcs11_certificate_real_get_markup (SeahorsePkcs11Certificate* self) {
-	g_return_val_if_fail (SEAHORSE_PKCS11_IS_CERTIFICATE (self), NULL);
+static char* seahorse_pkcs11_certificate_real_get_markup (SeahorseObject* base) {
+	SeahorsePkcs11Certificate* self;
+	self = SEAHORSE_PKCS11_CERTIFICATE (base);
 	return g_markup_escape_text (seahorse_object_get_display_name (SEAHORSE_OBJECT (self)), -1);
 }
 
@@ -242,8 +246,9 @@
 }
 
 
-static char* seahorse_pkcs11_certificate_real_get_stock_id (SeahorsePkcs11Certificate* self) {
-	g_return_val_if_fail (SEAHORSE_PKCS11_IS_CERTIFICATE (self), NULL);
+static char* seahorse_pkcs11_certificate_real_get_stock_id (SeahorseObject* base) {
+	SeahorsePkcs11Certificate* self;
+	self = SEAHORSE_PKCS11_CERTIFICATE (base);
 	/* TODO: A certificate icon */
 	return g_strdup ("");
 }
@@ -260,13 +265,13 @@
 		g_value_set_pointer (value, seahorse_pkcs11_certificate_get_pkcs11_attributes (self));
 		break;
 		case SEAHORSE_PKCS11_CERTIFICATE_DISPLAY_NAME:
-		g_value_set_string (value, seahorse_pkcs11_certificate_real_get_display_name (self));
+		g_value_set_string (value, seahorse_object_get_display_name (SEAHORSE_OBJECT (self)));
 		break;
 		case SEAHORSE_PKCS11_CERTIFICATE_DISPLAY_ID:
 		g_value_set_string (value, seahorse_pkcs11_certificate_get_display_id (self));
 		break;
 		case SEAHORSE_PKCS11_CERTIFICATE_MARKUP:
-		g_value_set_string (value, seahorse_pkcs11_certificate_real_get_markup (self));
+		g_value_set_string (value, seahorse_object_get_markup (SEAHORSE_OBJECT (self)));
 		break;
 		case SEAHORSE_PKCS11_CERTIFICATE_SIMPLE_NAME:
 		g_value_set_string (value, seahorse_pkcs11_certificate_get_simple_name (self));
@@ -293,7 +298,7 @@
 		g_value_set_string (value, seahorse_pkcs11_certificate_get_expires_str (self));
 		break;
 		case SEAHORSE_PKCS11_CERTIFICATE_STOCK_ID:
-		g_value_set_string (value, seahorse_pkcs11_certificate_real_get_stock_id (self));
+		g_value_set_string (value, seahorse_object_get_stock_id (SEAHORSE_OBJECT (self)));
 		break;
 		default:
 		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
@@ -324,7 +329,10 @@
 	g_type_class_add_private (klass, sizeof (SeahorsePkcs11CertificatePrivate));
 	G_OBJECT_CLASS (klass)->get_property = seahorse_pkcs11_certificate_get_property;
 	G_OBJECT_CLASS (klass)->set_property = seahorse_pkcs11_certificate_set_property;
-	G_OBJECT_CLASS (klass)->dispose = seahorse_pkcs11_certificate_dispose;
+	G_OBJECT_CLASS (klass)->finalize = seahorse_pkcs11_certificate_finalize;
+	SEAHORSE_OBJECT_CLASS (klass)->get_display_name = seahorse_pkcs11_certificate_real_get_display_name;
+	SEAHORSE_OBJECT_CLASS (klass)->get_markup = seahorse_pkcs11_certificate_real_get_markup;
+	SEAHORSE_OBJECT_CLASS (klass)->get_stock_id = seahorse_pkcs11_certificate_real_get_stock_id;
 	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAHORSE_PKCS11_CERTIFICATE_PKCS11_OBJECT, g_param_spec_object ("pkcs11-object", "pkcs11-object", "pkcs11-object", GP11_TYPE_OBJECT, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
 	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAHORSE_PKCS11_CERTIFICATE_PKCS11_ATTRIBUTES, g_param_spec_pointer ("pkcs11-attributes", "pkcs11-attributes", "pkcs11-attributes", G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
 	g_object_class_override_property (G_OBJECT_CLASS (klass), SEAHORSE_PKCS11_CERTIFICATE_DISPLAY_NAME, "display-name");
@@ -347,18 +355,18 @@
 }
 
 
-static void seahorse_pkcs11_certificate_dispose (GObject * obj) {
+static void seahorse_pkcs11_certificate_finalize (GObject * obj) {
 	SeahorsePkcs11Certificate * self;
 	self = SEAHORSE_PKCS11_CERTIFICATE (obj);
 	(self->priv->_pkcs11_object == NULL ? NULL : (self->priv->_pkcs11_object = (g_object_unref (self->priv->_pkcs11_object), NULL)));
 	(self->priv->_pkcs11_attributes == NULL ? NULL : (self->priv->_pkcs11_attributes = (gp11_attributes_unref (self->priv->_pkcs11_attributes), NULL)));
-	G_OBJECT_CLASS (seahorse_pkcs11_certificate_parent_class)->dispose (obj);
+	G_OBJECT_CLASS (seahorse_pkcs11_certificate_parent_class)->finalize (obj);
 }
 
 
 GType seahorse_pkcs11_certificate_get_type (void) {
 	static GType seahorse_pkcs11_certificate_type_id = 0;
-	if (G_UNLIKELY (seahorse_pkcs11_certificate_type_id == 0)) {
+	if (seahorse_pkcs11_certificate_type_id == 0) {
 		static const GTypeInfo g_define_type_info = { sizeof (SeahorsePkcs11CertificateClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) seahorse_pkcs11_certificate_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SeahorsePkcs11Certificate), 0, (GInstanceInitFunc) seahorse_pkcs11_certificate_instance_init };
 		seahorse_pkcs11_certificate_type_id = g_type_register_static (SEAHORSE_TYPE_OBJECT, "SeahorsePkcs11Certificate", &g_define_type_info, 0);
 	}

Modified: trunk/pkcs11/seahorse-pkcs11-certificate.h
==============================================================================
--- trunk/pkcs11/seahorse-pkcs11-certificate.h	(original)
+++ trunk/pkcs11/seahorse-pkcs11-certificate.h	Sun Aug 31 19:29:01 2008
@@ -6,6 +6,7 @@
 #include <glib-object.h>
 #include <seahorse-object.h>
 #include <gp11.h>
+#include <gp11-hacks.h>
 #include <stdlib.h>
 #include <string.h>
 

Modified: trunk/pkcs11/seahorse-pkcs11-certificate.vala
==============================================================================
--- trunk/pkcs11/seahorse-pkcs11-certificate.vala	(original)
+++ trunk/pkcs11/seahorse-pkcs11-certificate.vala	Sun Aug 31 19:29:01 2008
@@ -17,9 +17,11 @@
 		public override string# display_name {
 			get { 
 				if (_pkcs11_attributes != null) {
-					string label;
-					if (_pkcs11_attributes.find_string(P11.CKA_LABEL, out label))
-						return label;
+					string? label;
+					if (_pkcs11_attributes.find_string(P11.CKA_LABEL, out label)) {
+						if (label != null)
+							return label;
+					}
 				}
 				
 				/* TODO: Calculate something from the subject? */

Modified: trunk/pkcs11/seahorse-pkcs11-source.c
==============================================================================
--- trunk/pkcs11/seahorse-pkcs11-source.c	(original)
+++ trunk/pkcs11/seahorse-pkcs11-source.c	Sun Aug 31 19:29:01 2008
@@ -175,7 +175,7 @@
 static void _seahorse_pkcs11_source_updater_on_open_session_gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self);
 static GObject * seahorse_pkcs11_source_updater_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_properties);
 static gpointer seahorse_pkcs11_source_updater_parent_class = NULL;
-static void seahorse_pkcs11_source_updater_dispose (GObject * obj);
+static void seahorse_pkcs11_source_updater_finalize (GObject * obj);
 static GType seahorse_pkcs11_source_updater_get_type (void);
 struct _SeahorsePkcs11SourceRefresherPrivate {
 	GHashTable* _checks;
@@ -193,7 +193,7 @@
 static void seahorse_pkcs11_source_refresher_on_find_objects (SeahorsePkcs11SourceRefresher* self, GObject* obj, GAsyncResult* result);
 static GObject * seahorse_pkcs11_source_refresher_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_properties);
 static gpointer seahorse_pkcs11_source_refresher_parent_class = NULL;
-static void seahorse_pkcs11_source_refresher_dispose (GObject * obj);
+static void seahorse_pkcs11_source_refresher_finalize (GObject * obj);
 static GType seahorse_pkcs11_source_refresher_get_type (void);
 struct _SeahorsePkcs11SourceLoaderPrivate {
 	GP11Attributes* _unique_attrs;
@@ -211,7 +211,7 @@
 static GP11Attributes* seahorse_pkcs11_source_loader_get_unique_attrs (SeahorsePkcs11SourceLoader* self);
 static void seahorse_pkcs11_source_loader_set_unique_attrs (SeahorsePkcs11SourceLoader* self, GP11Attributes* value);
 static gpointer seahorse_pkcs11_source_loader_parent_class = NULL;
-static void seahorse_pkcs11_source_loader_dispose (GObject * obj);
+static void seahorse_pkcs11_source_loader_finalize (GObject * obj);
 static GType seahorse_pkcs11_source_loader_get_type (void);
 struct _SeahorsePkcs11SourceImporterPrivate {
 	GP11Attributes* _import_data;
@@ -230,7 +230,7 @@
 static void seahorse_pkcs11_source_importer_on_get_attribute (SeahorsePkcs11SourceImporter* self, GObject* obj, GAsyncResult* result);
 static GP11Attributes* seahorse_pkcs11_source_importer_get_import_data (SeahorsePkcs11SourceImporter* self);
 static gpointer seahorse_pkcs11_source_importer_parent_class = NULL;
-static void seahorse_pkcs11_source_importer_dispose (GObject * obj);
+static void seahorse_pkcs11_source_importer_finalize (GObject * obj);
 static GType seahorse_pkcs11_source_importer_get_type (void);
 struct _SeahorsePkcs11SourceRemoverPrivate {
 	GCancellable* _cancellable;
@@ -256,10 +256,10 @@
 static void _seahorse_pkcs11_source_remover_on_destroy_object_gasync_ready_callback (GObject* source_object, GAsyncResult* res, gpointer self);
 static GObject * seahorse_pkcs11_source_remover_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_properties);
 static gpointer seahorse_pkcs11_source_remover_parent_class = NULL;
-static void seahorse_pkcs11_source_remover_dispose (GObject * obj);
+static void seahorse_pkcs11_source_remover_finalize (GObject * obj);
 static GType seahorse_pkcs11_source_remover_get_type (void);
 static gpointer seahorse_pkcs11_source_parent_class = NULL;
-static void seahorse_pkcs11_source_dispose (GObject * obj);
+static void seahorse_pkcs11_source_finalize (GObject * obj);
 
 static const guint SEAHORSE_PKCS11_ATTRIBUTE_TYPES[] = {CKA_LABEL, CKA_ID, CKA_CLASS, CKA_TOKEN, CKA_GNOME_USER_TRUST, CKA_START_DATE, CKA_END_DATE};
 
@@ -375,7 +375,7 @@
 	SeahorsePkcs11Certificate* _tmp3;
 	g_return_if_fail (SEAHORSE_PKCS11_IS_SOURCE (self));
 	g_return_if_fail (GP11_IS_OBJECT (object));
-	g_return_if_fail (attrs != NULL);
+	g_return_if_fail (GP11_IS_ATTRIBUTES (attrs));
 	/* Build up an identifier for this object */
 	id = seahorse_pkcs11_id_from_attributes (attrs);
 	g_return_if_fail (id != 0);
@@ -712,7 +712,7 @@
 	G_OBJECT_CLASS (klass)->get_property = seahorse_pkcs11_source_updater_get_property;
 	G_OBJECT_CLASS (klass)->set_property = seahorse_pkcs11_source_updater_set_property;
 	G_OBJECT_CLASS (klass)->constructor = seahorse_pkcs11_source_updater_constructor;
-	G_OBJECT_CLASS (klass)->dispose = seahorse_pkcs11_source_updater_dispose;
+	G_OBJECT_CLASS (klass)->finalize = seahorse_pkcs11_source_updater_finalize;
 	SEAHORSE_PKCS11_SOURCE_UPDATER_CLASS (klass)->load_objects = seahorse_pkcs11_source_updater_real_load_objects;
 	SEAHORSE_OPERATION_CLASS (klass)->cancel = seahorse_pkcs11_source_updater_real_cancel;
 	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAHORSE_PKCS11_SOURCE_UPDATER_CANCELLABLE, g_param_spec_object ("cancellable", "cancellable", "cancellable", G_TYPE_CANCELLABLE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
@@ -725,20 +725,20 @@
 }
 
 
-static void seahorse_pkcs11_source_updater_dispose (GObject * obj) {
+static void seahorse_pkcs11_source_updater_finalize (GObject * obj) {
 	SeahorsePkcs11SourceUpdater * self;
 	self = SEAHORSE_PKCS11_SOURCE_UPDATER (obj);
 	(self->priv->_cancellable == NULL ? NULL : (self->priv->_cancellable = (g_object_unref (self->priv->_cancellable), NULL)));
 	(self->_source == NULL ? NULL : (self->_source = (g_object_unref (self->_source), NULL)));
 	(self->_session == NULL ? NULL : (self->_session = (g_object_unref (self->_session), NULL)));
 	(self->priv->_objects == NULL ? NULL : (self->priv->_objects = (_g_list_free_g_object_unref (self->priv->_objects), NULL)));
-	G_OBJECT_CLASS (seahorse_pkcs11_source_updater_parent_class)->dispose (obj);
+	G_OBJECT_CLASS (seahorse_pkcs11_source_updater_parent_class)->finalize (obj);
 }
 
 
 static GType seahorse_pkcs11_source_updater_get_type (void) {
 	static GType seahorse_pkcs11_source_updater_type_id = 0;
-	if (G_UNLIKELY (seahorse_pkcs11_source_updater_type_id == 0)) {
+	if (seahorse_pkcs11_source_updater_type_id == 0) {
 		static const GTypeInfo g_define_type_info = { sizeof (SeahorsePkcs11SourceUpdaterClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) seahorse_pkcs11_source_updater_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SeahorsePkcs11SourceUpdater), 0, (GInstanceInitFunc) seahorse_pkcs11_source_updater_instance_init };
 		seahorse_pkcs11_source_updater_type_id = g_type_register_static (SEAHORSE_TYPE_OPERATION, "SeahorsePkcs11SourceUpdater", &g_define_type_info, G_TYPE_FLAG_ABSTRACT);
 	}
@@ -901,7 +901,7 @@
 	seahorse_pkcs11_source_refresher_parent_class = g_type_class_peek_parent (klass);
 	g_type_class_add_private (klass, sizeof (SeahorsePkcs11SourceRefresherPrivate));
 	G_OBJECT_CLASS (klass)->constructor = seahorse_pkcs11_source_refresher_constructor;
-	G_OBJECT_CLASS (klass)->dispose = seahorse_pkcs11_source_refresher_dispose;
+	G_OBJECT_CLASS (klass)->finalize = seahorse_pkcs11_source_refresher_finalize;
 	SEAHORSE_PKCS11_SOURCE_UPDATER_CLASS (klass)->load_objects = seahorse_pkcs11_source_refresher_real_load_objects;
 }
 
@@ -911,17 +911,17 @@
 }
 
 
-static void seahorse_pkcs11_source_refresher_dispose (GObject * obj) {
+static void seahorse_pkcs11_source_refresher_finalize (GObject * obj) {
 	SeahorsePkcs11SourceRefresher * self;
 	self = SEAHORSE_PKCS11_SOURCE_REFRESHER (obj);
 	(self->priv->_checks == NULL ? NULL : (self->priv->_checks = (g_hash_table_unref (self->priv->_checks), NULL)));
-	G_OBJECT_CLASS (seahorse_pkcs11_source_refresher_parent_class)->dispose (obj);
+	G_OBJECT_CLASS (seahorse_pkcs11_source_refresher_parent_class)->finalize (obj);
 }
 
 
 static GType seahorse_pkcs11_source_refresher_get_type (void) {
 	static GType seahorse_pkcs11_source_refresher_type_id = 0;
-	if (G_UNLIKELY (seahorse_pkcs11_source_refresher_type_id == 0)) {
+	if (seahorse_pkcs11_source_refresher_type_id == 0) {
 		static const GTypeInfo g_define_type_info = { sizeof (SeahorsePkcs11SourceRefresherClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) seahorse_pkcs11_source_refresher_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SeahorsePkcs11SourceRefresher), 0, (GInstanceInitFunc) seahorse_pkcs11_source_refresher_instance_init };
 		seahorse_pkcs11_source_refresher_type_id = g_type_register_static (SEAHORSE_PKCS11_SOURCE_TYPE_UPDATER, "SeahorsePkcs11SourceRefresher", &g_define_type_info, 0);
 	}
@@ -934,7 +934,7 @@
 	GParameter * __params_it;
 	SeahorsePkcs11SourceLoader * self;
 	g_return_val_if_fail (SEAHORSE_PKCS11_IS_SOURCE (source), NULL);
-	g_return_val_if_fail (unique_attrs != NULL, NULL);
+	g_return_val_if_fail (GP11_IS_ATTRIBUTES (unique_attrs), NULL);
 	__params = g_new0 (GParameter, 2);
 	__params_it = __params;
 	__params_it->name = "source";
@@ -1056,7 +1056,7 @@
 	g_type_class_add_private (klass, sizeof (SeahorsePkcs11SourceLoaderPrivate));
 	G_OBJECT_CLASS (klass)->get_property = seahorse_pkcs11_source_loader_get_property;
 	G_OBJECT_CLASS (klass)->set_property = seahorse_pkcs11_source_loader_set_property;
-	G_OBJECT_CLASS (klass)->dispose = seahorse_pkcs11_source_loader_dispose;
+	G_OBJECT_CLASS (klass)->finalize = seahorse_pkcs11_source_loader_finalize;
 	SEAHORSE_PKCS11_SOURCE_UPDATER_CLASS (klass)->load_objects = seahorse_pkcs11_source_loader_real_load_objects;
 	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAHORSE_PKCS11_SOURCE_LOADER_UNIQUE_ATTRS, g_param_spec_pointer ("unique-attrs", "unique-attrs", "unique-attrs", G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
 }
@@ -1067,17 +1067,17 @@
 }
 
 
-static void seahorse_pkcs11_source_loader_dispose (GObject * obj) {
+static void seahorse_pkcs11_source_loader_finalize (GObject * obj) {
 	SeahorsePkcs11SourceLoader * self;
 	self = SEAHORSE_PKCS11_SOURCE_LOADER (obj);
 	(self->priv->_unique_attrs == NULL ? NULL : (self->priv->_unique_attrs = (gp11_attributes_unref (self->priv->_unique_attrs), NULL)));
-	G_OBJECT_CLASS (seahorse_pkcs11_source_loader_parent_class)->dispose (obj);
+	G_OBJECT_CLASS (seahorse_pkcs11_source_loader_parent_class)->finalize (obj);
 }
 
 
 static GType seahorse_pkcs11_source_loader_get_type (void) {
 	static GType seahorse_pkcs11_source_loader_type_id = 0;
-	if (G_UNLIKELY (seahorse_pkcs11_source_loader_type_id == 0)) {
+	if (seahorse_pkcs11_source_loader_type_id == 0) {
 		static const GTypeInfo g_define_type_info = { sizeof (SeahorsePkcs11SourceLoaderClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) seahorse_pkcs11_source_loader_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SeahorsePkcs11SourceLoader), 0, (GInstanceInitFunc) seahorse_pkcs11_source_loader_instance_init };
 		seahorse_pkcs11_source_loader_type_id = g_type_register_static (SEAHORSE_PKCS11_SOURCE_TYPE_UPDATER, "SeahorsePkcs11SourceLoader", &g_define_type_info, 0);
 	}
@@ -1090,7 +1090,7 @@
 	GParameter * __params_it;
 	SeahorsePkcs11SourceImporter * self;
 	g_return_val_if_fail (SEAHORSE_PKCS11_IS_SOURCE (source), NULL);
-	g_return_val_if_fail (import != NULL, NULL);
+	g_return_val_if_fail (GP11_IS_ATTRIBUTES (import), NULL);
 	__params = g_new0 (GParameter, 1);
 	__params_it = __params;
 	__params_it->name = "source";
@@ -1237,7 +1237,7 @@
 	seahorse_pkcs11_source_importer_parent_class = g_type_class_peek_parent (klass);
 	g_type_class_add_private (klass, sizeof (SeahorsePkcs11SourceImporterPrivate));
 	G_OBJECT_CLASS (klass)->get_property = seahorse_pkcs11_source_importer_get_property;
-	G_OBJECT_CLASS (klass)->dispose = seahorse_pkcs11_source_importer_dispose;
+	G_OBJECT_CLASS (klass)->finalize = seahorse_pkcs11_source_importer_finalize;
 	SEAHORSE_PKCS11_SOURCE_UPDATER_CLASS (klass)->load_objects = seahorse_pkcs11_source_importer_real_load_objects;
 	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAHORSE_PKCS11_SOURCE_IMPORTER_IMPORT_DATA, g_param_spec_pointer ("import-data", "import-data", "import-data", G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
 }
@@ -1248,17 +1248,17 @@
 }
 
 
-static void seahorse_pkcs11_source_importer_dispose (GObject * obj) {
+static void seahorse_pkcs11_source_importer_finalize (GObject * obj) {
 	SeahorsePkcs11SourceImporter * self;
 	self = SEAHORSE_PKCS11_SOURCE_IMPORTER (obj);
 	(self->priv->_import_data == NULL ? NULL : (self->priv->_import_data = (gp11_attributes_unref (self->priv->_import_data), NULL)));
-	G_OBJECT_CLASS (seahorse_pkcs11_source_importer_parent_class)->dispose (obj);
+	G_OBJECT_CLASS (seahorse_pkcs11_source_importer_parent_class)->finalize (obj);
 }
 
 
 static GType seahorse_pkcs11_source_importer_get_type (void) {
 	static GType seahorse_pkcs11_source_importer_type_id = 0;
-	if (G_UNLIKELY (seahorse_pkcs11_source_importer_type_id == 0)) {
+	if (seahorse_pkcs11_source_importer_type_id == 0) {
 		static const GTypeInfo g_define_type_info = { sizeof (SeahorsePkcs11SourceImporterClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) seahorse_pkcs11_source_importer_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SeahorsePkcs11SourceImporter), 0, (GInstanceInitFunc) seahorse_pkcs11_source_importer_instance_init };
 		seahorse_pkcs11_source_importer_type_id = g_type_register_static (SEAHORSE_PKCS11_SOURCE_TYPE_UPDATER, "SeahorsePkcs11SourceImporter", &g_define_type_info, 0);
 	}
@@ -1446,7 +1446,7 @@
 	G_OBJECT_CLASS (klass)->get_property = seahorse_pkcs11_source_remover_get_property;
 	G_OBJECT_CLASS (klass)->set_property = seahorse_pkcs11_source_remover_set_property;
 	G_OBJECT_CLASS (klass)->constructor = seahorse_pkcs11_source_remover_constructor;
-	G_OBJECT_CLASS (klass)->dispose = seahorse_pkcs11_source_remover_dispose;
+	G_OBJECT_CLASS (klass)->finalize = seahorse_pkcs11_source_remover_finalize;
 	SEAHORSE_OPERATION_CLASS (klass)->cancel = seahorse_pkcs11_source_remover_real_cancel;
 	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAHORSE_PKCS11_SOURCE_REMOVER_CANCELLABLE, g_param_spec_object ("cancellable", "cancellable", "cancellable", G_TYPE_CANCELLABLE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
 	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAHORSE_PKCS11_SOURCE_REMOVER_SOURCE, g_param_spec_object ("source", "source", "source", SEAHORSE_PKCS11_TYPE_SOURCE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT_ONLY));
@@ -1459,19 +1459,19 @@
 }
 
 
-static void seahorse_pkcs11_source_remover_dispose (GObject * obj) {
+static void seahorse_pkcs11_source_remover_finalize (GObject * obj) {
 	SeahorsePkcs11SourceRemover * self;
 	self = SEAHORSE_PKCS11_SOURCE_REMOVER (obj);
 	(self->priv->_cancellable == NULL ? NULL : (self->priv->_cancellable = (g_object_unref (self->priv->_cancellable), NULL)));
 	(self->priv->_source == NULL ? NULL : (self->priv->_source = (g_object_unref (self->priv->_source), NULL)));
 	(self->priv->_certificate == NULL ? NULL : (self->priv->_certificate = (g_object_unref (self->priv->_certificate), NULL)));
-	G_OBJECT_CLASS (seahorse_pkcs11_source_remover_parent_class)->dispose (obj);
+	G_OBJECT_CLASS (seahorse_pkcs11_source_remover_parent_class)->finalize (obj);
 }
 
 
 static GType seahorse_pkcs11_source_remover_get_type (void) {
 	static GType seahorse_pkcs11_source_remover_type_id = 0;
-	if (G_UNLIKELY (seahorse_pkcs11_source_remover_type_id == 0)) {
+	if (seahorse_pkcs11_source_remover_type_id == 0) {
 		static const GTypeInfo g_define_type_info = { sizeof (SeahorsePkcs11SourceRemoverClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) seahorse_pkcs11_source_remover_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SeahorsePkcs11SourceRemover), 0, (GInstanceInitFunc) seahorse_pkcs11_source_remover_instance_init };
 		seahorse_pkcs11_source_remover_type_id = g_type_register_static (SEAHORSE_TYPE_OPERATION, "SeahorsePkcs11SourceRemover", &g_define_type_info, 0);
 	}
@@ -1521,7 +1521,7 @@
 	g_type_class_add_private (klass, sizeof (SeahorsePkcs11SourcePrivate));
 	G_OBJECT_CLASS (klass)->get_property = seahorse_pkcs11_source_get_property;
 	G_OBJECT_CLASS (klass)->set_property = seahorse_pkcs11_source_set_property;
-	G_OBJECT_CLASS (klass)->dispose = seahorse_pkcs11_source_dispose;
+	G_OBJECT_CLASS (klass)->finalize = seahorse_pkcs11_source_finalize;
 	SEAHORSE_SOURCE_CLASS (klass)->load = seahorse_pkcs11_source_real_load;
 	SEAHORSE_PKCS11_SOURCE_CLASS (klass)->import = seahorse_pkcs11_source_real_import;
 	SEAHORSE_PKCS11_SOURCE_CLASS (klass)->export = seahorse_pkcs11_source_real_export;
@@ -1538,17 +1538,17 @@
 }
 
 
-static void seahorse_pkcs11_source_dispose (GObject * obj) {
+static void seahorse_pkcs11_source_finalize (GObject * obj) {
 	SeahorsePkcs11Source * self;
 	self = SEAHORSE_PKCS11_SOURCE (obj);
 	(self->priv->_slot == NULL ? NULL : (self->priv->_slot = (g_object_unref (self->priv->_slot), NULL)));
-	G_OBJECT_CLASS (seahorse_pkcs11_source_parent_class)->dispose (obj);
+	G_OBJECT_CLASS (seahorse_pkcs11_source_parent_class)->finalize (obj);
 }
 
 
 GType seahorse_pkcs11_source_get_type (void) {
 	static GType seahorse_pkcs11_source_type_id = 0;
-	if (G_UNLIKELY (seahorse_pkcs11_source_type_id == 0)) {
+	if (seahorse_pkcs11_source_type_id == 0) {
 		static const GTypeInfo g_define_type_info = { sizeof (SeahorsePkcs11SourceClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) seahorse_pkcs11_source_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SeahorsePkcs11Source), 0, (GInstanceInitFunc) seahorse_pkcs11_source_instance_init };
 		seahorse_pkcs11_source_type_id = g_type_register_static (SEAHORSE_TYPE_SOURCE, "SeahorsePkcs11Source", &g_define_type_info, 0);
 	}

Modified: trunk/pkcs11/seahorse-pkcs11-source.h
==============================================================================
--- trunk/pkcs11/seahorse-pkcs11-source.h	(original)
+++ trunk/pkcs11/seahorse-pkcs11-source.h	Sun Aug 31 19:29:01 2008
@@ -6,6 +6,7 @@
 #include <glib-object.h>
 #include <seahorse-source.h>
 #include <gp11.h>
+#include <gp11-hacks.h>
 #include <seahorse-operation.h>
 #include <gio/gio.h>
 #include <seahorse-object.h>

Modified: trunk/pkcs11/seahorse-pkcs11.c
==============================================================================
--- trunk/pkcs11/seahorse-pkcs11.c	(original)
+++ trunk/pkcs11/seahorse-pkcs11.c	Sun Aug 31 19:29:01 2008
@@ -43,7 +43,7 @@
 	char* _tmp4;
 	char* value;
 	GQuark _tmp5;
-	g_return_val_if_fail (attrs != NULL, 0U);
+	g_return_val_if_fail (GP11_IS_ATTRIBUTES (attrs), 0U);
 	/* These cases should have been covered by the programmer */
 	klass = 0UL;
 	if (!gp11_attributes_find_ulong (attrs, CKA_CLASS, &klass)) {
@@ -74,7 +74,7 @@
 	gint ckid_length1;
 	guchar* ckid;
 	gboolean _tmp6;
-	g_return_val_if_fail (attrs != NULL, FALSE);
+	g_return_val_if_fail (GP11_IS_ATTRIBUTES (attrs), FALSE);
 	if (id == 0) {
 		return FALSE;
 	}

Modified: trunk/pkcs11/seahorse-pkcs11.h
==============================================================================
--- trunk/pkcs11/seahorse-pkcs11.h	(original)
+++ trunk/pkcs11/seahorse-pkcs11.h	Sun Aug 31 19:29:01 2008
@@ -25,6 +25,7 @@
 #include <glib.h>
 #include <glib-object.h>
 #include <gp11.h>
+#include <gp11-hacks.h>
 
 G_BEGIN_DECLS
 

Modified: trunk/pkcs11/vala-build.stamp
==============================================================================
--- trunk/pkcs11/vala-build.stamp	(original)
+++ trunk/pkcs11/vala-build.stamp	Sun Aug 31 19:29:01 2008
@@ -1 +1 @@
-1217796417
+1220210715

Modified: trunk/ssh/vala-build.stamp
==============================================================================
--- trunk/ssh/vala-build.stamp	(original)
+++ trunk/ssh/vala-build.stamp	Sun Aug 31 19:29:01 2008
@@ -1 +1 @@
-1219784861
+1220209582



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