Attention is currently required from: Arne Schwabe.

Hello Arne Schwabe,

I'd like you to do a code review.
Please visit

    https://gerrit.openvpn.net/c/openvpn/+/2007?usp=email

to review the following change.


Change subject: ssl_verify_mbedtls: Avoid conversion warning in 
x509_get_fingerprint
......................................................................

ssl_verify_mbedtls: Avoid conversion warning in x509_get_fingerprint

We already convert mbedtls_md_get_size to int in other
places, so just use that here was well.

Change-Id: Iae70a03c2bcc502f62133abcbfd1c92528e65d69
Signed-off-by: Frank Lichtenheld <[email protected]>
---
M src/openvpn/ssl_verify_mbedtls.c
1 file changed, 1 insertion(+), 10 deletions(-)



  git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/07/2007/1

diff --git a/src/openvpn/ssl_verify_mbedtls.c b/src/openvpn/ssl_verify_mbedtls.c
index b9a36a6..6680ccc 100644
--- a/src/openvpn/ssl_verify_mbedtls.c
+++ b/src/openvpn/ssl_verify_mbedtls.c
@@ -542,25 +542,16 @@
     return FAILURE;
 }

-#if defined(__GNUC__) || defined(__clang__)
-#pragma GCC diagnostic push
-#pragma GCC diagnostic ignored "-Wconversion"
-#endif
-
 static struct buffer
 x509_get_fingerprint(const mbedtls_md_info_t *md_info, mbedtls_x509_crt *cert, 
struct gc_arena *gc)
 {
     const size_t md_size = mbedtls_md_get_size(md_info);
     struct buffer fingerprint = alloc_buf_gc(md_size, gc);
     mbedtls_md(md_info, cert->raw.p, cert->raw.len, BPTR(&fingerprint));
-    ASSERT(buf_inc_len(&fingerprint, md_size));
+    ASSERT(buf_inc_len(&fingerprint, (int)md_size));
     return fingerprint;
 }

-#if defined(__GNUC__) || defined(__clang__)
-#pragma GCC diagnostic pop
-#endif
-
 struct buffer
 x509_get_sha1_fingerprint(mbedtls_x509_crt *cert, struct gc_arena *gc)
 {

--
To view, visit https://gerrit.openvpn.net/c/openvpn/+/2007?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.openvpn.net/settings?usp=email

Gerrit-MessageType: newchange
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Iae70a03c2bcc502f62133abcbfd1c92528e65d69
Gerrit-Change-Number: 2007
Gerrit-PatchSet: 1
Gerrit-Owner: Frank Lichtenheld <[email protected]>
Gerrit-Reviewer: Arne Schwabe <[email protected]>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: Arne Schwabe <[email protected]>
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

Reply via email to