X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=bindings%2Fruby%2Fdatabase.c;h=bb993d8688848df012f26d4f9a545f31b78c195d;hb=d21e72c9f95d1d052360976302a2f9cfcc1556a5;hp=4ecc8f78f99225da983bbf6d16d0bdd0599e588e;hpb=9574fb60991fa81799fbd1d26d41693ca2794e6b;p=notmuch diff --git a/bindings/ruby/database.c b/bindings/ruby/database.c index 4ecc8f78..bb993d86 100644 --- a/bindings/ruby/database.c +++ b/bindings/ruby/database.c @@ -114,11 +114,7 @@ VALUE notmuch_rb_database_close (VALUE self) { notmuch_status_t ret; - notmuch_database_t *db; - - Data_Get_Notmuch_Database (self, db); - ret = notmuch_database_destroy (db); - DATA_PTR (self) = NULL; + ret = notmuch_rb_object_destroy (self, ¬much_rb_database_type); notmuch_rb_status_raise (ret); return Qnil;