[geary] Do not crash if ~/.local/share/geary does not exist. Bug 741883
- From: Michael Gratton <mjog src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geary] Do not crash if ~/.local/share/geary does not exist. Bug 741883
- Date: Sat, 10 Sep 2016 03:47:27 +0000 (UTC)
commit 46e176451fec6e75be08d315e2e2f54bbcc588d2
Author: Oskar Viljasaar <oskar viljasaar gmail com>
Date: Sat Jul 16 03:15:20 2016 +0200
Do not crash if ~/.local/share/geary does not exist. Bug 741883
src/client/util/util-migrate.vala | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/client/util/util-migrate.vala b/src/client/util/util-migrate.vala
index 1d92f54..17303c7 100644
--- a/src/client/util/util-migrate.vala
+++ b/src/client/util/util-migrate.vala
@@ -25,6 +25,10 @@ namespace Migrate {
File new_config_file;
File old_config_file;
+ // Return if Geary has never been run (~/.local/share/geary does not exist).
+ if (!user_data_dir.query_exists())
+ return;
+
// Create ~/.config/geary
try {
user_config_dir.make_directory_with_parents();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]