diff options
author | Nick Mathewson <nickm@torproject.org> | 2012-11-25 13:45:36 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2012-12-17 14:48:09 -0500 |
commit | f33487668f16dbd7f95eaf8644865c28e1dd7036 (patch) | |
tree | bde45b532fddf7d355561ff67ca7af1e98f0309f /src/or/addressmap.h | |
parent | 32219d83134c861abad5a7d37f93f3ec4b492398 (diff) | |
download | tor-f33487668f16dbd7f95eaf8644865c28e1dd7036.tar.gz tor-f33487668f16dbd7f95eaf8644865c28e1dd7036.zip |
Implement option to turn off DNS cache use on a client port
(This is part 2 of making DNS cache use enabled/disabled on a
per-client port basis. This implements the CacheIPv[46]DNS options,
but not the UseCachedIPv[46] ones.)
Diffstat (limited to 'src/or/addressmap.h')
-rw-r--r-- | src/or/addressmap.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/or/addressmap.h b/src/or/addressmap.h index 9b07341479..54b3e0ae7c 100644 --- a/src/or/addressmap.h +++ b/src/or/addressmap.h @@ -14,9 +14,12 @@ void addressmap_clean(time_t now); void addressmap_clear_configured(void); void addressmap_clear_transient(void); void addressmap_free_all(void); -int addressmap_rewrite(char *address, size_t maxlen, time_t *expires_out, +#define AMR_FLAG_USE_IPV4_DNS (1u<<0) +#define AMR_FLAG_USE_IPV6_DNS (1u<<1) +int addressmap_rewrite(char *address, size_t maxlen, unsigned flags, + time_t *expires_out, addressmap_entry_source_t *exit_source_out); -int addressmap_rewrite_reverse(char *address, size_t maxlen, +int addressmap_rewrite_reverse(char *address, size_t maxlen, unsigned flags, time_t *expires_out); int addressmap_have_mapping(const char *address, int update_timeout); |