[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [tor/release-0.3.2] Tweaks to strings in 24500
commit 779e4b9dcf850770a7c30104f714f4a59c2955a8
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date: Tue Dec 5 12:09:57 2017 -0500
Tweaks to strings in 24500
---
changes/ticket24500 | 4 ++--
src/common/crypto.c | 8 ++++----
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/changes/ticket24500 b/changes/ticket24500
index 0f1778d46..b49b7a555 100644
--- a/changes/ticket24500
+++ b/changes/ticket24500
@@ -1,3 +1,3 @@
- o Code simplification and refactoring:
- - Making more useful log messages for errno errors on getrandom() call.
+ o Minor features (logging):
+ - Provide better warnings when the getrandom() syscall fails.
Closes ticket 24500.
diff --git a/src/common/crypto.c b/src/common/crypto.c
index 7f034ee94..380f038f4 100644
--- a/src/common/crypto.c
+++ b/src/common/crypto.c
@@ -2877,12 +2877,12 @@ crypto_strongest_rand_syscall(uint8_t *out, size_t out_len)
/* Useful log message for errno. */
if (errno == ENOSYS) {
- log_warn(LD_CRYPTO, "This warning is caused by ENOSYS error."
+ log_warn(LD_CRYPTO, "Can't get entropy from getrandom(). "
" You are running a version of Tor built to support"
- " getrandom(), but the kernel is too old and doesn't"
- " implement this function.");
+ " getrandom(), but the kernel doesn't implement this"
+ " implement this function--probably because it is too old?");
} else {
- log_warn(LD_CRYPTO, "Can't get entropy from getrandom(). %s error.",
+ log_warn(LD_CRYPTO, "Can't get entropy from getrandom(): %s.",
strerror(errno));
}
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits