diff options
author | Nick Mathewson <nickm@torproject.org> | 2006-09-29 22:33:40 +0000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2006-09-29 22:33:40 +0000 |
commit | 7d366f61cb1b2b9965b02479c751a6987f328b76 (patch) | |
tree | d65fbad59801acc40f9098aef1470a53ce0af426 /src/common | |
parent | 8308a379086a82126f685f3d8668e48b0453880d (diff) | |
download | tor-7d366f61cb1b2b9965b02479c751a6987f328b76.tar tor-7d366f61cb1b2b9965b02479c751a6987f328b76.tar.gz |
r9025@Kushana: nickm | 2006-09-29 18:33:13 -0400
Differentiate more duplicated log entries
svn:r8542
Diffstat (limited to 'src/common')
-rw-r--r-- | src/common/compat.c | 5 | ||||
-rw-r--r-- | src/common/crypto.c | 2 | ||||
-rw-r--r-- | src/common/util.c | 10 |
3 files changed, 9 insertions, 8 deletions
diff --git a/src/common/compat.c b/src/common/compat.c index cddc73103..6fb15e379 100644 --- a/src/common/compat.c +++ b/src/common/compat.c @@ -652,12 +652,13 @@ switch_id(char *user, char *group) } if (setgid(gr->gr_gid) != 0) { - log_warn(LD_GENERAL,"Error setting GID: %s", strerror(errno)); + log_warn(LD_GENERAL,"Error setting to configured GID: %s", + strerror(errno)); return -1; } } else if (user) { if (setgid(pw->pw_gid) != 0) { - log_warn(LD_GENERAL,"Error setting GID: %s", strerror(errno)); + log_warn(LD_GENERAL,"Error setting to user GID: %s", strerror(errno)); return -1; } } diff --git a/src/common/crypto.c b/src/common/crypto.c index c7fea55eb..6cb0031fb 100644 --- a/src/common/crypto.c +++ b/src/common/crypto.c @@ -734,7 +734,7 @@ crypto_pk_public_checksig_digest(crypto_pk_env_t *env, const char *data, tor_assert(sig); if (crypto_digest(digest,data,datalen)<0) { - log_warn(LD_CRYPTO, "couldn't compute digest"); + log_warn(LD_BUG, "couldn't compute digest"); return -1; } r = crypto_pk_public_checksig(env,buf,sig,siglen); diff --git a/src/common/util.c b/src/common/util.c index 5294103cd..bc732c9ed 100644 --- a/src/common/util.c +++ b/src/common/util.c @@ -907,7 +907,7 @@ parse_rfc1123_time(const char *buf, time_t *t) } if (m<0) { char *esc = esc_for_log(buf); - log_warn(LD_GENERAL, "Got invalid RFC1123 time %s", esc); + log_warn(LD_GENERAL, "Got invalid RFC1123 time %s: No such month", esc); tor_free(esc); return -1; } @@ -958,17 +958,17 @@ parse_iso_time(const char *cp, time_t *t) struct tm st_tm; #ifdef HAVE_STRPTIME if (!strptime(cp, "%Y-%m-%d %H:%M:%S", &st_tm)) { - log_warn(LD_GENERAL, "Published time was unparseable"); return -1; + log_warn(LD_GENERAL, "ISO time was unparseable by strptime"); return -1; } #else unsigned int year=0, month=0, day=0, hour=100, minute=100, second=100; if (sscanf(cp, "%u-%u-%u %u:%u:%u", &year, &month, &day, &hour, &minute, &second) < 6) { - log_warn(LD_GENERAL, "Published time was unparseable"); return -1; + log_warn(LD_GENERAL, "ISO time time was unparseable"); return -1; } if (year < 1970 || month < 1 || month > 12 || day < 1 || day > 31 || hour > 23 || minute > 59 || second > 61) { - log_warn(LD_GENERAL, "Published time was nonsensical"); return -1; + log_warn(LD_GENERAL, "ISO time was nonsensical"); return -1; } st_tm.tm_year = year-1900; st_tm.tm_mon = month-1; @@ -1876,7 +1876,7 @@ get_interface_address(int severity, uint32_t *addr) /* XXXX Can this be right on IPv6 clients? */ if (getsockname(sock, (struct sockaddr*)&my_addr, &my_addr_len)) { int e = tor_socket_errno(sock); - log_fn(severity, LD_NET, "getsockname() failed: %s", + log_fn(severity, LD_NET, "getsockname() to determine interface failed: %s", tor_socket_strerror(e)); goto err; } |