summaryrefslogtreecommitdiff
path: root/src/or
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2008-04-22 16:23:51 +0000
committerNick Mathewson <nickm@torproject.org>2008-04-22 16:23:51 +0000
commita25b424d4b52096efa9cf0341cc6ed278c7b6c18 (patch)
tree186d3161d5585f8a3608c07c7726ecd1db125d0c /src/or
parent8a05bd90ce78c70e0c5a9362bcfda9c24f43f492 (diff)
downloadtor-a25b424d4b52096efa9cf0341cc6ed278c7b6c18.tar.gz
tor-a25b424d4b52096efa9cf0341cc6ed278c7b6c18.zip
r15270@tombo: nickm | 2008-04-22 12:23:39 -0400
Backport: Fix bug 663: warn less verbosely about clock skew from netinfo cells svn:r14409
Diffstat (limited to 'src/or')
-rw-r--r--src/or/command.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/or/command.c b/src/or/command.c
index d05f6cdae9..552624fb76 100644
--- a/src/or/command.c
+++ b/src/or/command.c
@@ -577,8 +577,11 @@ command_process_netinfo_cell(cell_t *cell, or_connection_t *conn)
if (labs(apparent_skew) > NETINFO_NOTICE_SKEW &&
router_get_by_digest(conn->identity_digest)) {
char dbuf[64];
- /*XXXX This should check the trustedness of the other side. */
- int severity = server_mode(get_options()) ? LOG_INFO : LOG_WARN;
+ int severity;
+ if (router_digest_is_trusted_dir(conn->identity_digest))
+ severity = LOG_WARN;
+ else
+ severity = LOG_INFO;
format_time_interval(dbuf, sizeof(dbuf), apparent_skew);
log_fn(severity, LD_GENERAL, "Received NETINFO cell with skewed time from "
"server at %s:%d. It seems that our clock is %s by %s, or "