Always use cvt_bin2hex

This commit is contained in:
SChernykh 2021-01-15 12:46:27 +01:00
parent 5c449913af
commit 7da04c6a2c

View file

@ -140,7 +140,6 @@ static int cvt_hex2bin(unsigned char *const bin, const size_t bin_maxlen, const
return ret; return ret;
} }
#define sodium_bin2hex cvt_bin2hex
#define sodium_hex2bin cvt_hex2bin #define sodium_hex2bin cvt_hex2bin
#endif #endif
@ -218,7 +217,7 @@ xmrig::Buffer xmrig::Cvt::fromHex(const char *in, size_t size)
bool xmrig::Cvt::toHex(char *hex, size_t hex_maxlen, const uint8_t *bin, size_t bin_len) bool xmrig::Cvt::toHex(char *hex, size_t hex_maxlen, const uint8_t *bin, size_t bin_len)
{ {
return sodium_bin2hex(hex, hex_maxlen, bin, bin_len) != nullptr; return cvt_bin2hex(hex, hex_maxlen, bin, bin_len) != nullptr;
} }