[gnome-software] Do not clear the recovery state when using gs_app_set_state_recover()
- From: Richard Hughes <rhughes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-software] Do not clear the recovery state when using gs_app_set_state_recover()
- Date: Fri, 22 Apr 2016 17:17:57 +0000 (UTC)
commit 7d8e4be0308d6b8889e0db96e5c19cb270ad83a2
Author: Richard Hughes <richard hughsie com>
Date: Fri Apr 22 13:06:36 2016 +0100
Do not clear the recovery state when using gs_app_set_state_recover()
If we do AVAILABLE->INSTALLING then recover (which puts us back at AVAILABLE)
then we do AVAILABLE->INSTALLING then recover we want to stay at AVAILABLE
rather than be at the new state of UNKNOWN.
src/gs-app.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/src/gs-app.c b/src/gs-app.c
index e811af1..3b2654a 100644
--- a/src/gs-app.c
+++ b/src/gs-app.c
@@ -453,8 +453,13 @@ gs_app_set_state_recover (GsApp *app)
return;
if (app->state_recover == app->state)
return;
+
+ g_debug ("recovering state on %s from %s to %s",
+ app->id,
+ as_app_state_to_string (app->state),
+ as_app_state_to_string (app->state_recover));
+
app->state = app->state_recover;
- app->state_recover = AS_APP_STATE_UNKNOWN;
gs_app_queue_notify (app, "state");
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]