mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-11 19:00:02 +01:00
crypto_backend.h: Wrap APIs in extern C
It's a good practice to mark public APIs as extern "C" so that projects written in C++ can use our library. [mbroz] It is not public API in cryptsetup, but we use this backend in other projects, this aligns the code changes. Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
committed by
Milan Broz
parent
b7cf60f229
commit
fb04611ff7
@@ -21,6 +21,10 @@
|
||||
#define char16_t uint16_t
|
||||
#endif
|
||||
|
||||
# ifdef __cplusplus
|
||||
extern "C" {
|
||||
# endif
|
||||
|
||||
struct crypt_hash;
|
||||
struct crypt_hmac;
|
||||
struct crypt_cipher;
|
||||
@@ -143,4 +147,8 @@ int crypt_backend_memeq(const void *m1, const void *m2, size_t n);
|
||||
/* crypto backend running in FIPS mode */
|
||||
bool crypt_fips_mode(void);
|
||||
|
||||
# ifdef __cplusplus
|
||||
}
|
||||
# endif
|
||||
|
||||
#endif /* _CRYPTO_BACKEND_H */
|
||||
|
||||
Reference in New Issue
Block a user