X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;ds=sidebyside;f=bindings%2Fruby%2Fdatabase.c;h=bb993d8688848df012f26d4f9a545f31b78c195d;hb=5f49e3421f5d1f98951b55dd5ba106c2a106aba7;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;