[Spice-commits] gtk/smartcard-manager.c
Marc-André Lureau
elmarco at kemper.freedesktop.org
Fri Nov 25 16:50:36 PST 2011
gtk/smartcard-manager.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit 290451601252e71d3c76ec62b5c19743dd00245f
Author: Marc-André Lureau <marcandre.lureau at gmail.com>
Date: Sat Nov 26 01:49:04 2011 +0100
Fix get_type() with --disable-smartcard
It's quite a bad hack, but I can't think of anything really better
Without this patch, g-ir-scanner introspection hangs with:
GLib-GObject-CRITICAL **: g_boxed_type_register_static: assertion `boxed_copy != NULL' failed
GLib-CRITICAL **: g_once_init_leave: assertion `result != 0' failed
GLib-GObject-WARNING **: gsignal.c:1585: parameter 1 of type `<invalid>' for sig
nal "SpiceSmartcardManager::reader_added" is not a value type
diff --git a/gtk/smartcard-manager.c b/gtk/smartcard-manager.c
index d814ac3..8ab4c3d 100644
--- a/gtk/smartcard-manager.c
+++ b/gtk/smartcard-manager.c
@@ -71,7 +71,8 @@ G_DEFINE_TYPE(SpiceSmartcardManager, spice_smartcard_manager, G_TYPE_OBJECT)
#ifdef USE_SMARTCARD
G_DEFINE_BOXED_TYPE(VReader, spice_smartcard_reader, vreader_reference, vreader_free)
#else
-G_DEFINE_BOXED_TYPE(GObject, spice_smartcard_reader, NULL, NULL)
+typedef GObject VReader;
+G_DEFINE_BOXED_TYPE(VReader, spice_smartcard_reader, g_object_ref, g_object_unref)
#endif
/* Properties */
More information about the Spice-commits
mailing list