[PATCH 3/7] Use notmuch_database_destroy instead of notmuch_database_close

Justus Winter 4winter at informatik.uni-hamburg.de
Sun Apr 22 05:07:53 PDT 2012


Adapt the notmuch binaries source to the notmuch_database_close split.

Signed-off-by: Justus Winter <4winter at informatik.uni-hamburg.de>
---
 notmuch-count.c   |    2 +-
 notmuch-dump.c    |    2 +-
 notmuch-new.c     |    2 +-
 notmuch-reply.c   |    2 +-
 notmuch-restore.c |    2 +-
 notmuch-search.c  |    2 +-
 notmuch-show.c    |    2 +-
 notmuch-tag.c     |    2 +-
 8 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/notmuch-count.c b/notmuch-count.c
index b76690c..9c2ad7b 100644
--- a/notmuch-count.c
+++ b/notmuch-count.c
@@ -107,7 +107,7 @@ notmuch_count_command (void *ctx, int argc, char *argv[])
     }
 
     notmuch_query_destroy (query);
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
 
     return 0;
 }
diff --git a/notmuch-dump.c b/notmuch-dump.c
index a735875..71ab0ea 100644
--- a/notmuch-dump.c
+++ b/notmuch-dump.c
@@ -116,7 +116,7 @@ notmuch_dump_command (unused (void *ctx), int argc, char *argv[])
 	fclose (output);
 
     notmuch_query_destroy (query);
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
 
     return 0;
 }
diff --git a/notmuch-new.c b/notmuch-new.c
index 4f13535..f078753 100644
--- a/notmuch-new.c
+++ b/notmuch-new.c
@@ -1017,7 +1017,7 @@ notmuch_new_command (void *ctx, int argc, char *argv[])
 		notmuch_status_to_string (ret));
     }
 
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
 
     if (run_hooks && !ret && !interrupted)
 	ret = notmuch_run_hook (db_path, "post-new");
diff --git a/notmuch-reply.c b/notmuch-reply.c
index 0949d9f..da99a13 100644
--- a/notmuch-reply.c
+++ b/notmuch-reply.c
@@ -755,7 +755,7 @@ notmuch_reply_command (void *ctx, int argc, char *argv[])
 	return 1;
 
     notmuch_query_destroy (query);
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
 
     if (params.cryptoctx)
 	g_object_unref(params.cryptoctx);
diff --git a/notmuch-restore.c b/notmuch-restore.c
index d3b9246..02b563c 100644
--- a/notmuch-restore.c
+++ b/notmuch-restore.c
@@ -192,7 +192,7 @@ notmuch_restore_command (unused (void *ctx), int argc, char *argv[])
     if (line)
 	free (line);
 
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
     if (input != stdin)
 	fclose (input);
 
diff --git a/notmuch-search.c b/notmuch-search.c
index 1cc8430..7dfd270 100644
--- a/notmuch-search.c
+++ b/notmuch-search.c
@@ -545,7 +545,7 @@ notmuch_search_command (void *ctx, int argc, char *argv[])
     }
 
     notmuch_query_destroy (query);
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
 
     return ret;
 }
diff --git a/notmuch-show.c b/notmuch-show.c
index da4a797..3b6667c 100644
--- a/notmuch-show.c
+++ b/notmuch-show.c
@@ -1117,7 +1117,7 @@ notmuch_show_command (void *ctx, unused (int argc), unused (char *argv[]))
     }
 
     notmuch_query_destroy (query);
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
 
     if (params.cryptoctx)
 	g_object_unref(params.cryptoctx);
diff --git a/notmuch-tag.c b/notmuch-tag.c
index 05feed3..bd56fd1 100644
--- a/notmuch-tag.c
+++ b/notmuch-tag.c
@@ -238,7 +238,7 @@ notmuch_tag_command (void *ctx, int argc, char *argv[])
 
     ret = tag_query (ctx, notmuch, query_string, tag_ops, synchronize_flags);
 
-    notmuch_database_close (notmuch);
+    notmuch_database_destroy (notmuch);
 
     return ret;
 }
-- 
1.7.10



More information about the notmuch mailing list