Debian Codegraph @

debian/rust-vendor/aws-lc-sys/aws-lc/crypto/pool/internal.h

raw
1 // Copyright (c) 2016, Google Inc.
2 // SPDX-License-Identifier: ISC
3
4 #ifndef OPENSSL_HEADER_POOL_INTERNAL_H
5 #define OPENSSL_HEADER_POOL_INTERNAL_H
6
7 #include <openssl/lhash.h>
8 #include <openssl/thread.h>
9
10 #include "../lhash/internal.h"
11
12
13 #if defined(__cplusplus)
14 extern "C" {
15 #endif
16
17
18 DEFINE_LHASH_OF(CRYPTO_BUFFER)
19
20 struct crypto_buffer_st {
21 CRYPTO_BUFFER_POOL *pool;
22 uint8_t *data;
23 size_t len;
24 CRYPTO_refcount_t references;
25 int data_is_static;
26 };
27
28 struct crypto_buffer_pool_st {
29 LHASH_OF(CRYPTO_BUFFER) *bufs;
30 CRYPTO_MUTEX lock;
31 const uint64_t hash_key[2];
32 };
33
34
35 #if defined(__cplusplus)
36 } // extern C
37 #endif
38
39 #endif // OPENSSL_HEADER_POOL_INTERNAL_H