summaryrefslogtreecommitdiff
path: root/include/openssl/e_os2.h
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2019-02-15 08:06:36 +0100
committerRichard Levitte <levitte@openssl.org>2019-02-15 11:44:35 +0100
commit48fe4ce104df060dd5d2b4188a56eb554d94d819 (patch)
treecf10b38186c0b540ba2ad7f165e72ba9ae7f43e3 /include/openssl/e_os2.h
parent088dfa133561d7613b9391a56ddbce58f32c934a (diff)
downloadopenssl-new-48fe4ce104df060dd5d2b4188a56eb554d94d819.tar.gz
Mark generated functions unused (applies to safestack, lhash, sparse_array)
safestack.h, lhash.h and sparse_array.h all define macros to generate a full API for the containers as static inline functions. This potentially generates unused code, which some compilers may complain about. We therefore need to mark those generated functions as unused, so the compiler knows that we know, and stops complaining about it. Reviewed-by: Nicola Tuveri <nic.tuv@gmail.com> (Merged from https://github.com/openssl/openssl/pull/8246)
Diffstat (limited to 'include/openssl/e_os2.h')
-rw-r--r--include/openssl/e_os2.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/openssl/e_os2.h b/include/openssl/e_os2.h
index 002cea3b7f..b88abc1791 100644
--- a/include/openssl/e_os2.h
+++ b/include/openssl/e_os2.h
@@ -287,6 +287,13 @@ typedef unsigned __int64 uint64_t;
# define ossl_noreturn
# endif
+/* ossl_unused: portable unused attribute for use in public headers */
+# if defined(__GNUC__)
+# define ossl_unused __attribute__((unused))
+# else
+# define ossl_unused
+# endif
+
#ifdef __cplusplus
}
#endif