]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/shared/gcrypt-util.h
Add SPDX license identifiers to source files under the LGPL
[thirdparty/systemd.git] / src / shared / gcrypt-util.h
index 1da12a32be28b2d627bd7aacb67f31247372d26e..69faf08e56fd5ddab79b64a68097c24cedf9e90a 100644 (file)
@@ -1,3 +1,4 @@
+/* SPDX-License-Identifier: LGPL-2.1+ */
 /*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
 
 /***
@@ -23,7 +24,7 @@
 #include <stdbool.h>
 #include <stddef.h>
 
-#ifdef HAVE_GCRYPT
+#if HAVE_GCRYPT
 #include <gcrypt.h>
 
 void initialize_libgcrypt(bool secmem);
@@ -31,7 +32,7 @@ int string_hashsum(const char *s, size_t len, int md_algorithm, char **out);
 #endif
 
 static inline int string_hashsum_sha224(const char *s, size_t len, char **out) {
-#ifdef HAVE_GCRYPT
+#if HAVE_GCRYPT
         return string_hashsum(s, len, GCRY_MD_SHA224, out);
 #else
         return -EOPNOTSUPP;
@@ -39,7 +40,7 @@ static inline int string_hashsum_sha224(const char *s, size_t len, char **out) {
 }
 
 static inline int string_hashsum_sha256(const char *s, size_t len, char **out) {
-#ifdef HAVE_GCRYPT
+#if HAVE_GCRYPT
         return string_hashsum(s, len, GCRY_MD_SHA256, out);
 #else
         return -EOPNOTSUPP;