[gssdp] Be less annoying with deprecation warnings



commit 1b9e9b0668feb3618e34d0e9b62152e673eee618
Author: Jens Georg <mail jensge org>
Date:   Fri Jul 29 10:56:55 2011 +0200

    Be less annoying with deprecation warnings

 libgssdp/gssdp-client.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/libgssdp/gssdp-client.c b/libgssdp/gssdp-client.c
index 363d734..7bbc71d 100644
--- a/libgssdp/gssdp-client.c
+++ b/libgssdp/gssdp-client.c
@@ -321,8 +321,9 @@ gssdp_client_set_property (GObject      *object,
                                             g_value_get_string (value));
                 break;
         case PROP_MAIN_CONTEXT:
-                g_warning ("GSSDPClient:main-context is deprecated."
-                           " Please use g_main_context_push_thread_default()");
+                if (g_value_get_pointer (value) != NULL)
+                        g_warning ("GSSDPClient:main-context is deprecated."
+                                   " Please use g_main_context_push_thread_default()");
                 break;
         case PROP_IFACE:
                 client->priv->iface = g_value_dup_string (value);



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