X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;ds=sidebyside;f=bindings%2Fruby%2Fmessages.c;h=6369d0523008b6dadda38bc58cde3c8c908badf5;hb=HEAD;hp=e04f3af143bb30a4bcffea595615fc7e9ae5e6ff;hpb=9574fb60991fa81799fbd1d26d41693ca2794e6b;p=notmuch diff --git a/bindings/ruby/messages.c b/bindings/ruby/messages.c index e04f3af1..6369d052 100644 --- a/bindings/ruby/messages.c +++ b/bindings/ruby/messages.c @@ -28,12 +28,7 @@ VALUE notmuch_rb_messages_destroy (VALUE self) { - notmuch_messages_t *messages; - - Data_Get_Notmuch_Messages (self, messages); - - notmuch_messages_destroy (messages); - DATA_PTR (self) = NULL; + notmuch_rb_object_destroy (self, ¬much_rb_messages_type); return Qnil; } @@ -76,5 +71,5 @@ notmuch_rb_messages_collect_tags (VALUE self) if (!tags) rb_raise (notmuch_rb_eMemoryError, "Out of memory"); - return Data_Wrap_Notmuch_Object (notmuch_rb_cTags, ¬much_rb_tags_type, tags); + return notmuch_rb_tags_get (tags); }