Nick Mathewson
668f7a2639
Do not send Libevent log messages to a controller (0.2.1 backport)
...
Doing so could make Libevent call Libevent from inside a Libevent
logging call, which is a recipe for reentrant confusion and
hard-to-debug crashes. This would especially hurt if Libevent
debug-level logging is enabled AND the user has a controller
watching for low-severity log messages.
Fix bug 2190; fix on 0.1.0.2-rc.
2010-11-19 22:27:40 -05:00
Nick Mathewson
c3e63483b2
Update Tor Project copyright years
2010-02-27 17:14:21 -05:00
Sebastian Hahn
aea9cf1011
Fix compile warnings on Snow Leopard
...
Big thanks to nickm and arma for helping me with this!
2009-09-01 18:36:27 +02:00
Nick Mathewson
9d11827780
Fix a rare infinite-recursion bug when shutting down.
...
Once we had called log_free_all(), anything that tried to log a
message (like a failed tor_assert()) would fail like this:
1. The logging call eventually invokes the _log() function.
2. _log() calls tor_mutex_lock(log_mutex).
3. tor_mutex_lock(m) calls tor_assert(m).
4. Since we freed the log_mutex, tor_assert() fails, and tries to
log its failure.
5. GOTO 1.
Now we allocate the mutex statically, and never destroy it on
shutdown.
Bugfix on 0.2.0.16-alpha, which introduced the log mutex.
This bug was found by Matt Edman.
2009-08-20 11:55:33 -04:00
Karsten Loesing
9b32e8c141
Update copyright to 2009.
2009-05-04 11:28:27 -04:00
Nick Mathewson
72e420ff3c
Fix typo found by Justin Coffi on or-talk
...
svn:r18258
2009-01-23 22:45:08 +00:00
Nick Mathewson
c4b8fef362
Remove svn $Id$s from our source, and remove tor --version --version.
...
The subversion $Id$ fields made every commit force a rebuild of
whatever file got committed. They were not actually useful for
telling the version of Tor files in the wild.
svn:r17867
2009-01-04 00:35:51 +00:00
Nick Mathewson
52932d6f1a
Remove some code that is #ifdefed out, and that we no longer seem to use, if we ever did.
...
svn:r17827
2008-12-30 04:16:49 +00:00
Nick Mathewson
b4d387c28b
Make freelist_len in memarea.c static; document a few variables.
...
svn:r17741
2008-12-22 19:14:08 +00:00
Nick Mathewson
b68379b13b
Add DOCDOC entries for undocumented static and global variables.
...
svn:r17739
2008-12-22 19:00:05 +00:00
Nick Mathewson
1e5f457461
Fix most DOCDOCs remaining and/or added by redox.
...
svn:r17734
2008-12-22 17:53:04 +00:00
Nick Mathewson
b6f89a647a
One log.c XXX021 was a misunderstanding. Also, clip log messages passed to syslog to their maximum length when there is a maximum.
...
svn:r17688
2008-12-18 17:18:06 +00:00
Nick Mathewson
6693f32530
Resolve many DOCDOCs.
...
svn:r17662
2008-12-17 22:58:20 +00:00
Nick Mathewson
bd6b3072f9
Change logging code to use fds instead of stdio. Fixes bug 861, and probably makes logging slightly faster. Not a backport candidate: bug 861 is too obscure and harmless.
...
svn:r17456
2008-12-02 23:36:58 +00:00
Nick Mathewson
bdc0aec00a
Update _log_global_min_severity after switch_logs_debug(), so that USR2 will work again. Bugfix on 0.1.2.8-beta. Spotted by Geoff Down.
...
svn:r17317
2008-11-17 19:58:51 +00:00
Nick Mathewson
f28fc83ea5
More logging for mtbf/wfu calculations.
...
svn:r16941
2008-09-23 18:24:20 +00:00
Nick Mathewson
8ea780632f
Make severity args to add_*_log() functions be const
...
svn:r16775
2008-09-05 19:52:44 +00:00
Peter Palfrader
9d132fbde6
Add --hush switch.
...
New --hush command-line option similar to --quiet. While --quiet disables all
logging to the console on startup, --hush limits the output to messages of
warning and error severity.
svn:r14222
2008-03-27 17:25:49 +00:00
Nick Mathewson
02acee891c
r19089@catbus: nickm | 2008-03-27 11:05:23 -0400
...
Free some static hashtables and the log mutex on exit. Backport candidate.
svn:r14212
2008-03-27 15:05:28 +00:00
Roger Dingledine
e9221f4a0d
fix a leak when adding a temp log
...
svn:r14203
2008-03-26 18:59:45 +00:00
Roger Dingledine
8dfccf6145
fix mem leak in parsing log config lines
...
svn:r14202
2008-03-26 18:36:46 +00:00
Nick Mathewson
bd547e3cfc
r18861@catbus: nickm | 2008-03-16 23:22:56 -0400
...
Fix a couple of bugs in setting control log callback severity.
svn:r14065
2008-03-17 03:37:52 +00:00
Nick Mathewson
46155aca17
r18804@catbus: nickm | 2008-03-13 18:18:31 -0400
...
Refactor log domain mask code so that nobody outside of log.c has to use SEVERITY_MASK_IDX. It is error-prone.
svn:r14016
2008-03-13 22:18:38 +00:00
Nick Mathewson
d928e5685f
r18803@catbus: nickm | 2008-03-13 17:59:25 -0400
...
Fix behavior of switch_logs_debug() in trunk. Fixes bug 626. Bugfix on r13875.
svn:r14015
2008-03-13 22:18:36 +00:00
Peter Palfrader
e6b2d119e8
Assert that severity in logv() is sane. Interesting effects otherwise (It is being used as an array index)
...
svn:r14006
2008-03-13 16:56:14 +00:00
Nick Mathewson
11e464c331
r18753@catbus: nickm | 2008-03-11 14:56:39 -0400
...
Make some assert()s into tor_assert()s. Make some tor_assert()s called from logging into assert()s, and document why.
svn:r13977
2008-03-11 18:56:41 +00:00
Nick Mathewson
7587e16796
r18639@catbus: nickm | 2008-03-07 20:11:48 -0500
...
Change semantics of add-a-log functions to copy severity setup: that is way less error-prone. Fix up config.c to act accordingly.
svn:r13888
2008-03-08 01:11:54 +00:00
Nick Mathewson
f56ba5f3d6
r18630@catbus: nickm | 2008-03-05 17:31:33 -0500
...
Implement domain-selection for logging. Source is documented; needs documentation in manpage (maybe). For now, see doxygen comment on parse_log_severity_config in log.c
svn:r13875
2008-03-05 22:31:39 +00:00
Nick Mathewson
b375472d14
r14373@tombo: nickm | 2008-02-21 16:29:18 -0500
...
Apply warnings about implicit 64-to-32 conversions; some from Sebastian Hahn; some not.
svn:r13664
2008-02-21 21:57:42 +00:00
Nick Mathewson
842a33ff20
Update some copyright notices: it is now 2008.
...
svn:r13412
2008-02-07 05:31:47 +00:00
Nick Mathewson
a869574c56
r17947@catbus: nickm | 2008-02-06 11:57:53 -0500
...
Fix a bunch of DOCDOC items; document the --quiet flag; refactor a couple of XXXX020 items.
svn:r13405
2008-02-06 16:58:05 +00:00
Nick Mathewson
c0ec281565
r15784@tombo: nickm | 2008-01-02 00:38:06 -0500
...
Fix bug 575: protect the list of logs with a mutex. I couldn't find any appreciable change in logging performance on osx, but ymmv. You can undef USE_LOG_MUTEX to see if stuff gets faster for you.
svn:r13019
2008-01-02 05:38:53 +00:00
Roger Dingledine
1d8a8063b9
clean up copyrights, and assign 2007 copyrights to The Tor Project, Inc
...
svn:r12786
2007-12-12 21:09:01 +00:00
Roger Dingledine
6d2cb32d10
free some more memory on exit
...
svn:r10837
2007-07-16 04:33:47 +00:00
Nick Mathewson
e11a92bd54
r13058@catbus: nickm | 2007-05-29 14:39:53 -0400
...
Note that the fix for bug 222 should technically be turned into a real fix, not a kludge, one of these days.
svn:r10397
2007-05-29 18:39:59 +00:00
Nick Mathewson
e5ed434c42
r13054@catbus: nickm | 2007-05-29 14:20:50 -0400
...
An even better workaround for the probably-already-fixed bug 222.
svn:r10395
2007-05-29 18:21:00 +00:00
Nick Mathewson
f89a3b1448
r13050@catbus: nickm | 2007-05-29 13:31:11 -0400
...
Resolve all but 3 DOCDOCs.
svn:r10393
2007-05-29 17:31:13 +00:00
Nick Mathewson
e935d73b34
r12852@catbus: nickm | 2007-05-22 11:00:27 -0400
...
Use svn revisions consistently throughout all log messages.
svn:r10291
2007-05-22 15:48:46 +00:00
Roger Dingledine
440b7f0c70
polish r9726-r9903
...
svn:r10182
2007-05-13 09:25:06 +00:00
Nick Mathewson
fa39336e65
r12607@catbus: nickm | 2007-04-30 21:36:28 -0400
...
More attempt to fix win32 building. This time, with extra linking.
svn:r10080
2007-05-01 01:36:32 +00:00
Nick Mathewson
f25e2167f5
r12533@Kushana: nickm | 2007-03-11 05:01:15 -0400
...
Oh. Tor was supposed to compile?
svn:r9797
2007-03-11 09:05:17 +00:00
Nick Mathewson
4a6e29b029
r12076@catbus: nickm | 2007-03-04 15:41:04 -0500
...
oops; remove spurious argument from _log_prefix.
svn:r9734
2007-03-04 21:08:26 +00:00
Nick Mathewson
7fcceb2c25
r12074@catbus: nickm | 2007-03-04 15:11:43 -0500
...
Make all LD_BUG log messsages get prefixed with "Bug: ". Remove manually-generated "Bug: "s from log-messages. (Apparently, we remembered to add them about 40% of the time.)
svn:r9733
2007-03-04 20:11:46 +00:00
Nick Mathewson
0fb179aa2e
r11860@catbus: nickm | 2007-02-21 00:56:15 -0500
...
Another optimization suggested by Shark output: shave off >90% of uses of logv by cutting down on calls to log_debug when log actually debugging. This is showing up in some profiles bug not others, and might be as much as 2.5%.
svn:r9612
2007-02-21 05:57:12 +00:00
Nick Mathewson
759c58151e
r11775@catbus: nickm | 2007-02-12 16:39:09 -0500
...
Update copyright dates.
svn:r9570
2007-02-12 21:39:53 +00:00
Nick Mathewson
8507699256
r11624@catbus: nickm | 2007-02-01 13:17:35 -0500
...
Note a few questionable bits pointed out by RATS. (And no, RATS, I'm not about to stop having fixed-sized local buffers for you. I know how to use them, thankyouverymuch.)
svn:r9474
2007-02-01 18:33:02 +00:00
Roger Dingledine
936f075f11
help ftello find its prototype
...
svn:r9016
2006-12-02 23:08:55 +00:00
Roger Dingledine
f2bd0e2f16
more minor cleanups
...
svn:r8630
2006-10-07 06:28:50 +00:00
Nick Mathewson
87648bdcf8
r9008@Kushana: nickm | 2006-09-29 13:50:10 -0400
...
Doxygen comments for code in common. Also simplify a few code paths to be more clear/speedy/correct.
svn:r8536
2006-09-29 18:13:37 +00:00
Nick Mathewson
05604c60d4
r9006@Kushana: nickm | 2006-09-29 10:48:23 -0400
...
Omit function names from NOTICE, WARN and ERR messages unless they are in LD_BUG.
svn:r8534
2006-09-29 18:13:29 +00:00