From d7d314f128b9ea1b8c7598c180a673fe964135df Mon Sep 17 00:00:00 2001 From: Simon Rozman Date: Mon, 24 Oct 2016 14:13:04 +0200 Subject: [PATCH] eap_error_runtime introduced --- include/WinStd/EAP.h | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/include/WinStd/EAP.h b/include/WinStd/EAP.h index 72428bbf..5caf42a9 100644 --- a/include/WinStd/EAP.h +++ b/include/WinStd/EAP.h @@ -62,7 +62,7 @@ namespace winstd typedef std::unique_ptr WINSTD_API eap_blob_runtime; /// - /// Deleter for unique_ptr to EAP_ERROR using EapHostPeerFreeEapError + /// Deleter for unique_ptr to EAP_ERROR using EapHostPeerFreeErrorMemory /// struct WINSTD_API EapHostPeerFreeErrorMemory_delete; @@ -71,6 +71,16 @@ namespace winstd /// typedef std::unique_ptr WINSTD_API eap_error; + /// + /// Deleter for unique_ptr to EAP_ERROR using EapHostPeerFreeEapError + /// + struct WINSTD_API EapHostPeerFreeEapError_delete; + + /// + /// EAP_ERROR wrapper class + /// + typedef std::unique_ptr WINSTD_API eap_error_runtime; + /// /// EAP_ATTRIBUTE wrapper class /// @@ -225,6 +235,23 @@ namespace winstd }; + struct WINSTD_API EapHostPeerFreeEapError_delete + { + /// + /// Default constructor + /// + EapHostPeerFreeEapError_delete() {} + + /// + /// Delete a pointer + /// + void operator()(EAP_ERROR *_Ptr) const + { + EapHostPeerFreeEapError(_Ptr); + } + }; + + class WINSTD_API __declspec(novtable) eap_attr : public EAP_ATTRIBUTE { public: