Skip to content

Commit b3372d6

Browse files
committed
use my_random_bytes() that correctly detects error conditions
1 parent 2119647 commit b3372d6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sql/item_strfunc.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1517,7 +1517,7 @@ String *Item_func_random_bytes::val_str(String *str)
15171517
goto err;
15181518

15191519
str->length(count);
1520-
if (!RAND_bytes((unsigned char *) str->ptr(), (int32) count))
1520+
if (my_random_bytes((unsigned char *) str->ptr(), (int32) count))
15211521
{
15221522
ulong ssl_err;
15231523
while ((ssl_err= ERR_get_error()))

0 commit comments

Comments
 (0)