310-polarssl-disable-runtime-version-check.patch 863 B

12345678910111213141516171819202122
  1. --- a/lib/vtls/polarssl.c
  2. +++ b/lib/vtls/polarssl.c
  3. @@ -665,7 +665,7 @@ void Curl_polarssl_session_free(void *pt
  4. size_t Curl_polarssl_version(char *buffer, size_t size)
  5. {
  6. - unsigned int version = version_get_number();
  7. + unsigned int version = POLARSSL_VERSION_NUMBER;
  8. return snprintf(buffer, size, "%s/%d.%d.%d",
  9. version >= 0x01030A00?"mbedTLS":"PolarSSL",
  10. version>>24, (version>>16)&0xff, (version>>8)&0xff);
  11. --- a/lib/vtls/mbedtls.c
  12. +++ b/lib/vtls/mbedtls.c
  13. @@ -705,7 +705,7 @@ void Curl_mbedtls_session_free(void *ptr
  14. size_t Curl_mbedtls_version(char *buffer, size_t size)
  15. {
  16. - unsigned int version = mbedtls_version_get_number();
  17. + unsigned int version = MBEDTLS_VERSION_NUMBER;
  18. return snprintf(buffer, size, "mbedTLS/%d.%d.%d", version>>24,
  19. (version>>16)&0xff, (version>>8)&0xff);
  20. }