]> rtime.felk.cvut.cz Git - notmuch.git/commitdiff
go: add return status to database close method
authorPeter Wang <novalazy@gmail.com>
Wed, 16 Apr 2014 12:59:19 +0000 (22:59 +1000)
committerDavid Bremner <david@tethera.net>
Tue, 16 Sep 2014 18:17:06 +0000 (20:17 +0200)
Add return status to the Database.Close() method that calls
notmuch_database_destroy.

bindings/go/src/notmuch/notmuch.go

index 00bd53acc3cab3f8866553ce4a3abe85a5ac6208..b9230ad2c3455852724b3ea6b3ed2287acb65ecb 100644 (file)
@@ -144,8 +144,8 @@ func OpenDatabase(path string, mode DatabaseMode) (*Database, Status) {
 
 /* Close the given notmuch database, freeing all associated
  * resources. See notmuch_database_open. */
-func (self *Database) Close() {
-       C.notmuch_database_destroy(self.db)
+func (self *Database) Close() Status {
+       return Status(C.notmuch_database_destroy(self.db))
 }
 
 /* Return the database path of the given database.