static char *ossl_strerror(unsigned long error, char *buf, size_t size)
{
  if(size)
    *buf = '\0';

#ifdef OPENSSL_IS_BORINGSSL
  ERR_error_string_n((uint32_t)error, buf, size);
#else
  ERR_error_string_n(error, buf, size);
#endif

  if(size > 1 && !*buf) {
    strncpy(buf, (error ? "Unknown error" : "No error"), size);
    buf[size - 1] = '\0';
  }

  return buf;
}
static char *ossl_strerror(unsigned long error, char *buf, size_t size)
{
  if(size)
    *buf = '\0';

#ifdef OPENSSL_IS_BORINGSSL
  ERR_error_string_n((uint32_t)error, buf, size);
#else
  ERR_error_string_n(error, buf, size);
#endif

  if(size > 1 && !*buf) {
    strncpy(buf, (error ? "Unknown error" : "No error"), size);
    buf[size - 1] = '\0';
  }

  return buf;
}