[spice-server 1/3] gobject: Add g_type_init() for older glibs

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

 



Older glib versions require g_type_init() to be called before using
GObject.
---
 server/reds.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/server/reds.c b/server/reds.c
index 23df51a..fdfb54a 100644
--- a/server/reds.c
+++ b/server/reds.c
@@ -3394,6 +3394,9 @@ static int do_spice_init(RedsState *reds, SpiceCoreInterface *core_interface)
 {
     spice_info("starting %s", VERSION);
 
+#if !GLIB_CHECK_VERSION(2,36,0)
+    g_type_init();
+#endif
     if (core_interface->base.major_version != SPICE_INTERFACE_CORE_MAJOR) {
         spice_warning("bad core interface version");
         goto err;
-- 
2.5.5

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]