[empathy] empathy.c: check return value of unique_app_send_message (#629782)



commit 7d891f1e506421c8f05700d4b8d4df5b228eabf9
Author: Guillaume Desmottes <guillaume desmottes collabora co uk>
Date:   Thu Sep 16 10:47:46 2010 +0200

    empathy.c: check return value of unique_app_send_message (#629782)

 src/empathy.c |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/src/empathy.c b/src/empathy.c
index 0128b7b..f22d69b 100644
--- a/src/empathy.c
+++ b/src/empathy.c
@@ -461,10 +461,12 @@ main (int argc, char *argv[])
 
   if (unique_app_is_running (unique_app))
     {
-      unique_app_send_message (unique_app, UNIQUE_ACTIVATE, NULL);
-
-      g_object_unref (unique_app);
-      return EXIT_SUCCESS;
+      if (unique_app_send_message (unique_app, UNIQUE_ACTIVATE, NULL) ==
+          UNIQUE_RESPONSE_OK)
+        {
+          g_object_unref (unique_app);
+          return EXIT_SUCCESS;
+        }
     }
 
   notify_init (_(PACKAGE_NAME));



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