[almanah] Add more debugging on failure to encrypt the database
- From: Philip Withnall <pwithnall src gnome org>
- To: svn-commits-list gnome org
- Subject: [almanah] Add more debugging on failure to encrypt the database
- Date: Thu, 23 Apr 2009 12:58:37 -0400 (EDT)
commit 5c5c5c92223b29a44a9dd10746eb1708c2275842
Author: Philip Withnall <philip tecnocode co uk>
Date: Thu Apr 23 17:58:08 2009 +0100
Add more debugging on failure to encrypt the database
---
src/storage-manager.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/src/storage-manager.c b/src/storage-manager.c
index b38bbb0..43c2287 100644
--- a/src/storage-manager.c
+++ b/src/storage-manager.c
@@ -308,9 +308,11 @@ database_idle_cb (CipherOperation *operation)
AlmanahStorageManager *self = operation->storage_manager;
gpgme_error_t error_gpgme;
- if (!(gpgme_wait (operation->context, &error_gpgme, FALSE) == NULL && error_gpgme == 0)) {
+ if (gpgme_wait (operation->context, &error_gpgme, FALSE) != NULL || error_gpgme != GPG_ERR_NO_ERROR) {
struct stat db_stat;
+ g_warning (_("Error encrypting database: %s"), gpgme_strerror (error_gpgme));
+
/* Check to see if the encrypted file is 0B in size, which isn't good.
* Not much we can do about it except quit without deleting the plaintext database. */
g_stat (self->priv->filename, &db_stat);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]