Mark an argument of an inline function as unused
authorPeter Eisentraut <peter@eisentraut.org>
Thu, 16 Jul 2020 08:18:16 +0000 (10:18 +0200)
committerTomas Mraz <tmraz@fedoraproject.org>
Tue, 4 Aug 2020 11:34:38 +0000 (13:34 +0200)
This allows users of this header file to compile their own code with
the gcc option -Wunused-parameter.

CLA: trivial

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/12459)

include/openssl/err.h

index fd3b93aa47de7a25cf415b7136e249764701a1c3..77bbba4f9f50f7eb4481a542be27131f57e1b1ef 100644 (file)
@@ -221,7 +221,7 @@ static ossl_inline int ERR_GET_LIB(unsigned long errcode)
     return (errcode >> ERR_LIB_OFFSET) & ERR_LIB_MASK;
 }
 
-static ossl_inline int ERR_GET_FUNC(unsigned long errcode)
+static ossl_inline int ERR_GET_FUNC(unsigned long errcode ossl_unused)
 {
     return 0;
 }