summaryrefslogtreecommitdiff
path: root/src/or/geoip.h
AgeCommit message (Collapse)Author
2012-02-09Count IPv6 connections in bridge and entry stats.Karsten Loesing
2011-08-04Clean up bridge-stats code.Karsten Loesing
Only write a bridge-stats string if bridge stats have been initialized. This behavior is similar to dirreq-stats, entry-stats, etc. Also add a few unit tests for the bridge-stats code.
2011-08-04Separate generation of an entry-stats string from writing it to disk.Karsten Loesing
This commit is similar to the previous two commits for dirreq-stats, but for entry-stats.
2011-08-04Separate generation of a dirreq-stats string from writing it to disk.Karsten Loesing
This patch separates the generation of a dirreq-stats string from actually writing it to disk. The new geoip_format_dirreq_stats() generates a dirreq-stats string that geoip_dirreq_stats_write() writes to disk. All the state changing (e.g., resetting the dirreq-stats history and initializing the next measurement interval) takes place in geoip_dirreq_stats_write(). That allows us to finally test the dirreq-stats code better.
2011-06-14Make the get_options() return constNick Mathewson
This lets us make a lot of other stuff const, allows the compiler to generate (slightly) better code, and will make me get slightly fewer patches from folks who stick mutable stuff into or_options_t. const: because not every input is an output!
2011-04-07Merge remote-tracking branch 'origin/maint-0.2.2'Nick Mathewson
2011-04-07Allow controllers a more up-to-date view of bridge usage.Nick Mathewson
Instead of answering GETINFO requests about our geoip usage only after running for 24 hours, this patch makes us answer GETINFO requests immediately. We still round and quantize as before. Implements bug2711. Also, refactor the heck out of the bridge usage formatting code. No longer should we need to do a generate-parse-and-regenerate cycle to get the controller string, and that lets us simplify the code a lot.
2011-01-03Merge remote branch 'origin/maint-0.2.2'Nick Mathewson
2011-01-03Bump copyright statements to 2011 (0.2.2)Nick Mathewson
2010-11-09Add GeoIP file digest to extra-info descriptor.Karsten Loesing
2010-08-05Allow enabling or disabling *Statistics while Tor is running.Karsten Loesing
With this patch we stop scheduling when we should write statistics using a single timestamp in run_scheduled_events(). Instead, we remember when a statistics interval starts separately for each statistic type in geoip.c and rephist.c. Every time run_scheduled_events() tries to write stats to disk, it learns when it should schedule the next such attempt. This patch also enables all statistics to be stopped and restarted at a later time. This patch comes with a few refactorings, some of which were not easily doable without the patch.
2010-07-27Create geoip.hSebastian Hahn