]> git.notmuchmail.org Git - notmuch/blobdiff - bindings/ruby/thread.c
ruby: new notmuch_rb_object_destroy() helper
[notmuch] / bindings / ruby / thread.c
index f6bf7849b12ab578626fc6f95344c353d2a06c2d..7cb2a3dcc6ebeacdd5c4c37b726a53056c436a5c 100644 (file)
 VALUE
 notmuch_rb_thread_destroy (VALUE self)
 {
-    notmuch_thread_t *thread;
-
-    Data_Get_Notmuch_Thread (self, thread);
-
-    notmuch_thread_destroy (thread);
-    DATA_PTR (self) = NULL;
+    notmuch_rb_object_destroy (self, &notmuch_rb_thread_type);
 
     return Qnil;
 }