use my_random_bytes() that correctly detects error conditions
This commit is contained in:
parent
2119647f7d
commit
b3372d6422
@ -1517,7 +1517,7 @@ String *Item_func_random_bytes::val_str(String *str)
|
|||||||
goto err;
|
goto err;
|
||||||
|
|
||||||
str->length(count);
|
str->length(count);
|
||||||
if (!RAND_bytes((unsigned char *) str->ptr(), (int32) count))
|
if (my_random_bytes((unsigned char *) str->ptr(), (int32) count))
|
||||||
{
|
{
|
||||||
ulong ssl_err;
|
ulong ssl_err;
|
||||||
while ((ssl_err= ERR_get_error()))
|
while ((ssl_err= ERR_get_error()))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user