summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Pipping <sebastian@pipping.org>2017-07-20 21:51:44 +0200
committerSebastian Pipping <sebastian@pipping.org>2017-07-26 20:35:52 +0200
commitcfd6b138d60ff7c7a7d3f440da8dee7374795098 (patch)
treebed0926f66ccd88b6e127ac388d0883e31937d2d
parente081e04ea0761838c3f6e720dde839ccff0ee37d (diff)
downloadlibexpat-git-cfd6b138d60ff7c7a7d3f440da8dee7374795098.tar.gz
xmlparse.c: Rename writeRandomBytes_getrandom to ..._nonblock
.. to better communicate the nature of that function
-rw-r--r--expat/lib/xmlparse.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/expat/lib/xmlparse.c b/expat/lib/xmlparse.c
index 64ac7025..2b2a15bd 100644
--- a/expat/lib/xmlparse.c
+++ b/expat/lib/xmlparse.c
@@ -754,7 +754,7 @@ static const XML_Char implicitContext[] = {
/* Obtain entropy on Linux 3.17+ */
static int
-writeRandomBytes_getrandom(void * target, size_t count) {
+writeRandomBytes_getrandom_nonblock(void * target, size_t count) {
int success = 0; /* full count bytes written? */
size_t bytesWrittenTotal = 0;
const unsigned int getrandomFlags = GRND_NONBLOCK;
@@ -901,7 +901,7 @@ generate_hash_secret_salt(XML_Parser parser)
return ENTROPY_DEBUG("RtlGenRandom", entropy);
}
#elif defined(HAVE_GETRANDOM) || defined(HAVE_SYSCALL_GETRANDOM)
- if (writeRandomBytes_getrandom((void *)&entropy, sizeof(entropy))) {
+ if (writeRandomBytes_getrandom_nonblock((void *)&entropy, sizeof(entropy))) {
return ENTROPY_DEBUG("getrandom", entropy);
}
#endif