639. [bug] Reading entropy from the keyboard would sometimes fail.
[RT #591] note: the entropy callback conventions should really be documented.
This commit is contained in:
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: result.h,v 1.52 2000/11/18 02:56:47 gson Exp $ */
|
||||
/* $Id: result.h,v 1.53 2000/12/27 00:11:25 bwelling Exp $ */
|
||||
|
||||
#ifndef ISC_RESULT_H
|
||||
#define ISC_RESULT_H 1
|
||||
@@ -74,10 +74,11 @@
|
||||
#define ISC_R_FAMILYNOSUPPORT 48 /* AF not supported */
|
||||
#define ISC_R_BADHEX 49 /* bad hex encoding */
|
||||
#define ISC_R_TOOMANYOPENFILES 50 /* too many open files */
|
||||
#define ISC_R_NOTBLOCKING 51 /* not blocking */
|
||||
/*
|
||||
* Not a result code: the number of results.
|
||||
*/
|
||||
#define ISC_R_NRESULTS 51
|
||||
#define ISC_R_NRESULTS 52
|
||||
|
||||
ISC_LANG_BEGINDECLS
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: result.c,v 1.51 2000/12/06 00:30:07 tale Exp $ */
|
||||
/* $Id: result.c,v 1.52 2000/12/27 00:11:24 bwelling Exp $ */
|
||||
|
||||
#include <config.h>
|
||||
|
||||
@@ -88,7 +88,8 @@ static const char *text[ISC_R_NRESULTS] = {
|
||||
"address family mismatch", /* 47 */
|
||||
"address family not supported", /* 48 */
|
||||
"bad hex encoding", /* 49 */
|
||||
"too many open files" /* 50 */
|
||||
"too many open files", /* 50 */
|
||||
"not blocking" /* 51 */
|
||||
};
|
||||
|
||||
#define ISC_RESULT_RESULTSET 2
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: entropy.c,v 1.53 2000/12/14 22:40:17 gson Exp $ */
|
||||
/* $Id: entropy.c,v 1.54 2000/12/27 00:11:26 bwelling Exp $ */
|
||||
|
||||
#include <config.h>
|
||||
|
||||
@@ -442,7 +442,8 @@ get_from_callback(isc_entropysource_t *source, unsigned int desired,
|
||||
added += got;
|
||||
desired -= ISC_MIN(got, desired);
|
||||
result = ISC_R_SUCCESS;
|
||||
} else if (result != ISC_R_SUCCESS)
|
||||
} else if (result != ISC_R_SUCCESS &&
|
||||
result != ISC_R_NOTBLOCKING)
|
||||
source->bad = ISC_TRUE;
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user