aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/tls/tls_extensions.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/tls/tls_extensions.h')
-rw-r--r--src/lib/tls/tls_extensions.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lib/tls/tls_extensions.h b/src/lib/tls/tls_extensions.h
index a88938eba..ac1f75a2b 100644
--- a/src/lib/tls/tls_extensions.h
+++ b/src/lib/tls/tls_extensions.h
@@ -372,6 +372,12 @@ class Extensions
return nullptr;
}
+ template<typename T>
+ bool has() const
+ {
+ return get<T>() != nullptr;
+ }
+
void add(Extension* extn)
{
extensions[extn->type()].reset(extn);