Commit 70ba5516 authored by Mark Andrews's avatar Mark Andrews

2957. [bug] entropy_get() and entropy_getpseudo() failed to match

                        the API for RAND_bytes() and RAND_pseudo_bytes()
                        respectively. [RT #21962]
parent 2df9c63c
2957. [bug] entropy_get() and entropy_getpseudo() failed to match
the API for RAND_bytes() and RAND_pseudo_bytes()
respectively. [RT #21962]
2956. [port] Enable atomic operations on the PowerPC64. [RT #21899]
2955. [func] Provide more detail in the recursing log. [RT #22043]
......
......@@ -31,7 +31,7 @@
/*
* Principal Author: Brian Wellington
* $Id: openssl_link.c,v 1.27 2009/10/05 17:30:49 fdupont Exp $
* $Id: openssl_link.c,v 1.28 2010/09/15 03:06:15 marka Exp $
*/
#ifdef OPENSSL
......@@ -79,7 +79,7 @@ entropy_get(unsigned char *buf, int num) {
if (num < 0)
return (-1);
result = dst__entropy_getdata(buf, (unsigned int) num, ISC_FALSE);
return (result == ISC_R_SUCCESS ? num : -1);
return (result == ISC_R_SUCCESS ? 1 : -1);
}
static int
......@@ -93,7 +93,7 @@ entropy_getpseudo(unsigned char *buf, int num) {
if (num < 0)
return (-1);
result = dst__entropy_getdata(buf, (unsigned int) num, ISC_TRUE);
return (result == ISC_R_SUCCESS ? num : -1);
return (result == ISC_R_SUCCESS ? 1 : -1);
}
static void
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment