[vino/gnome-3-0] Only call g_settings_sync() when necessary



commit 22325d03e3a0af868a067ac31d720c9d59f30409
Author: David King <amigadave amigadave com>
Date:   Fri Jul 8 12:49:46 2011 +0200

    Only call g_settings_sync() when necessary
    
    Versions of Gio since 2.29.2 call g_settings_sync() during GApplication
    shutdown, thus it is not required to call it manually, bug 653914.

 capplet/vino-preferences.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
---
diff --git a/capplet/vino-preferences.c b/capplet/vino-preferences.c
index e9d3f0b..fd0b516 100644
--- a/capplet/vino-preferences.c
+++ b/capplet/vino-preferences.c
@@ -493,7 +493,12 @@ main (int argc, char **argv)
   app = vino_preferences_new ();
   status = g_application_run (G_APPLICATION(app), argc, argv);
   g_object_unref (app);
+/* g_settings_sync() is not required with GApplication in recent versions of
+ * Gio, bug 653914. */
+#if GLIB_CHECK_VERSION (2, 29, 2)
+#else
   g_settings_sync ();
+#endif
 
   return status;
 }



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