go: add return status to database close method

Add return status to the Database.Close() method that calls
notmuch_database_destroy.
This commit is contained in:
Peter Wang 2014-04-16 22:59:19 +10:00 committed by David Bremner
parent ea90d8e043
commit d81fc4b42d

View 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.