[gnome-packagekit] Check for success before we do the restart check
- From: Richard Hughes <rhughes src gnome org>
- To: svn-commits-list gnome org
- Subject: [gnome-packagekit] Check for success before we do the restart check
- Date: Tue, 28 Jul 2009 15:28:50 +0000 (UTC)
commit 56b4b4162ce2f8bd68331d502ebefd0963e71a74
Author: Richard Hughes <richard hughsie com>
Date: Tue Jul 28 09:46:59 2009 +0100
Check for success before we do the restart check
src/gpk-watch.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
---
diff --git a/src/gpk-watch.c b/src/gpk-watch.c
index 7bf870f..5e2cc9a 100644
--- a/src/gpk-watch.c
+++ b/src/gpk-watch.c
@@ -453,6 +453,12 @@ gpk_watch_task_list_finished_cb (PkTaskList *tlist, PkClient *client, PkExitEnum
}
egg_debug ("role=%s, text=%s", pk_role_enum_to_text (role), text);
+ /* is it worth processing? */
+ if (exit_enum != PK_EXIT_ENUM_SUCCESS) {
+ egg_debug ("not processing, as didn't complete okay");
+ goto out;
+ }
+
/* show an icon if the user needs to reboot */
if (role == PK_ROLE_ENUM_UPDATE_PACKAGES ||
role == PK_ROLE_ENUM_INSTALL_PACKAGES ||
@@ -493,12 +499,6 @@ no_data:
goto out;
}
- /* is it worth showing a UI? */
- if (exit_enum != PK_EXIT_ENUM_SUCCESS) {
- egg_debug ("not notifying, as didn't complete okay");
- goto out;
- }
-
/* are we accepting notifications */
value = gconf_client_get_bool (watch->priv->gconf_client, GPK_CONF_NOTIFY_COMPLETED, NULL);
if (!value) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]