summaryrefslogtreecommitdiffhomepage
path: root/options/scoped.hpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2021-10-15 23:58:49 +0200
committerStanislaw Halik <sthalik@misaki.pl>2021-10-16 18:20:50 +0200
commit6d953ab8a790312c46c04264a328741c949ad830 (patch)
tree93e3b5f6776efa48ff6dfad74ac4ea0e4c89ff72 /options/scoped.hpp
parentb9a4d906f1cde54ba05dd8be8d4971f0fa51d98e (diff)
options/opts: allow disable raii guard
Diffstat (limited to 'options/scoped.hpp')
-rw-r--r--options/scoped.hpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/options/scoped.hpp b/options/scoped.hpp
index dd7dbacf..81e6bd19 100644
--- a/options/scoped.hpp
+++ b/options/scoped.hpp
@@ -27,9 +27,13 @@ struct OTR_OPTIONS_EXPORT opts
opts& operator=(const opts&) = delete;
opts(const opts&) = delete;
+ void set_raii_dtor_state(bool x) { raii = x; }
+
protected:
explicit opts(const QString& name);
~opts();
+private:
+ bool raii = true;
};
}