engines/http: silence openssl 3.0 deprecation warnings
authorJens Axboe <axboe@kernel.dk>
Tue, 19 Jul 2022 19:21:19 +0000 (13:21 -0600)
committerJens Axboe <axboe@kernel.dk>
Tue, 19 Jul 2022 19:21:19 +0000 (13:21 -0600)
Maybe someone will fix these one day, for now shut up the annoying
warning about certain functions being deprecated. Example:

engines/http.c: In function ‘_gen_hex_md5’:
engines/http.c:261:9: warning: ‘MD5’ is deprecated: Since OpenSSL 3.0 [-Wdeprecated-declarations]
  261 |         MD5((unsigned char*)p, len, hash);
      |         ^~~
In file included from engines/http.c:28:
/usr/include/openssl/md5.h:52:38: note: declared here
   52 | OSSL_DEPRECATEDIN_3_0 unsigned char *MD5(const unsigned char *d, size_t n,
      |                                      ^~~
engines/http.c: In function ‘_hmac’:
engines/http.c:273:9: warning: ‘HMAC_CTX_new’ is deprecated: Since OpenSSL 3.0 [-Wdeprecated-declarations]
  273 |         ctx = HMAC_CTX_new();
      |         ^~~

Signed-off-by: Jens Axboe <axboe@kernel.dk>
engines/http.c

index b6df70f8d8a8e461632f7caf5af5bfd8157b0e30..1de9e66c75f793e641e1605c678f19c17b00c8db 100644 (file)
 #include "fio.h"
 #include "../optgroup.h"
 
+/*
+ * Silence OpenSSL 3.0 deprecated function warnings
+ */
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
 
 enum {
        FIO_HTTP_WEBDAV     = 0,