[gnome-boxes] machine: Ensure "Saving…" statu s goes away on error
- From: Zeeshan Ali Khattak <zeeshanak src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-boxes] machine: Ensure "Saving…" statu s goes away on error
- Date: Mon, 27 Apr 2015 16:08:42 +0000 (UTC)
commit 8569b3af4f71c454b57bf15be5ef38fd620a7733
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date: Mon Apr 27 17:04:36 2015 +0100
machine: Ensure "Saving…" status goes away on error
If saving of machine fails, the "Saving…" status message under the
machine thumbnail in overview does not disappear. This patch ensures
that it does.
https://bugzilla.gnome.org/show_bug.cgi?id=748381
src/machine.vala | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/src/machine.vala b/src/machine.vala
index 4159eab..81cd884 100644
--- a/src/machine.vala
+++ b/src/machine.vala
@@ -264,9 +264,11 @@ private abstract class Boxes.Machine: Boxes.CollectionItem, Boxes.IPropertiesPro
this.info = (info != null)? info + "\n" : "";
this.info += _("Saving…");
- yield save_real ();
-
- this.info = info;
+ try {
+ yield save_real ();
+ } finally {
+ this.info = info;
+ }
}
public void schedule_autosave () {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]