ruby: New exception Notmuch::UnbalancedAtomicError
[notmuch] / bindings / ruby / init.c
index a516ab9800d6099557660406f2155ee4d95fe8a9..72e1a478cd35b84b2d62cb36f7432db8d6fb8b25 100644 (file)
@@ -166,7 +166,14 @@ Init_notmuch(void)
      */
     notmuch_rb_eUnbalancedFreezeThawError = rb_define_class_under(mod, "UnbalancedFreezeThawError",
             notmuch_rb_eBaseError);
-
+    /*
+     * Document-class: Notmuch::UnbalancedAtomicError
+     *
+     * Raised when notmuch_database_end_atomic has been called more times than
+     * notmuch_database_begin_atomic
+     */
+    notmuch_rb_eUnbalancedAtomicError = rb_define_class_under(mod, "UnbalancedAtomicError",
+            notmuch_rb_eBaseError);
     /*
      * Document-class: Notmuch::Database
      *