Gray C++ Libraries  0.0.2
A set of C++ libraries for MSVC, GNU on Windows, WinCE, Linux
GraySSLInt.h
Go to the documentation of this file.
1 //
4 //
5 #ifndef _INC_GraySSLInt_H
6 #define _INC_GraySSLInt_H
7 #ifndef NO_PRAGMA_ONCE
8 #pragma once
9 #endif
10 
11 #include "cSSLCompileOptions.h"
12 
14 #include "GrayLib/include/Cert/cX509.h" // X509_Verify_t
15 
16 namespace GraySSL
17 {
18  using namespace GrayLib;
19  using namespace Gray; // introduce my namespace.
20 
21 #ifndef GRAYSSL_LINK
22 #if defined(_MFC_VER) || defined(GRAY_STATICLIB) // GRAY_STATICLIB or _MFC_VER can be defined to make Gray* all static lib
23 #define GRAYSSL_LINK
24 #else
25 #define GRAYSSL_LINK __DECL_IMPORT
26 #endif
27 #endif
28 
29 #define FACILITY_GRAYSSL 0x101 // HRESULT FACILITY_TYPE const ?
30 
32  {
33  // S_OK = 0,
34  // E_FAIL, E_NOTIMPL, DISP_E_BUFFERTOOSMALL, E_OUTOFMEMORY
35 
36 #define GRAYSSL_ERR(a,b,c) GRAYSSL_ERR_##a = b, // c
37 #include "GraySSLError.tbl"
38 #undef GRAYSSL_ERR
39 
40  GRAYSSL_ERR_MASK = 0x00FF,
41  };
42 
44  {
45  // FACILITY_GRAYSSL error codes.
46  ASSERT((b & GRAYSSL_ERR_MASK) == b);
47  return MAKE_HRESULT(1, FACILITY_GRAYSSL, b);
48  }
49 }
50 
51 #endif
#define FACILITY_GRAYSSL
Definition: GraySSLInt.h:29
#define MAKE_HRESULT(sev, fac, code)
Definition: HResult.h:77
INT32 HRESULT
_WIN32 style error codes. INT32
Definition: SysTypes.h:465
#define ASSERT(exp)
Definition: cDebugAssert.h:87
Definition: cMesh.h:22
Definition: GraySSL.cpp:11
HRESULT GRAYSSL_ERR1(GRAYSSL_ERR_t b)
Definition: GraySSLInt.h:43
GRAYSSL_ERR_t
Definition: GraySSLInt.h:32
@ GRAYSSL_ERR_MASK
Definition: GraySSLInt.h:40
< The main namespace for all Core functions.
Definition: GrayCore.cpp:14