Tor
0.4.7.0-alpha-dev
|
Public Member Functions | |
HANDLE_ENTRY (consensus_cache_entry, consensus_cache_entry_t) | |
Data Fields | |
uint32_t | magic |
int32_t | refcnt |
unsigned | can_remove: 1 |
unsigned | release_aggressively: 1 |
char * | fname |
config_line_t * | labels |
consensus_cache_t * | in_cache |
time_t | unused_since |
tor_mmap_t * | map |
size_t | bodylen |
const uint8_t * | body |
A consensus_cache_entry_t is a reference-counted handle to an item in a consensus_cache_t. It can be mmapped into RAM, or not, depending whether it's currently in use.
Definition at line 32 of file conscache.c.
const uint8_t* body |
Pointer to the body within map.
Definition at line 56 of file conscache.c.
Referenced by consensus_cache_entry_map(), and directory_handle_command().
size_t bodylen |
Length of the body within map.
Definition at line 54 of file conscache.c.
Referenced by consensus_cache_entry_map().
unsigned can_remove |
If true, we want to delete this file.
Definition at line 36 of file conscache.c.
Referenced by consensus_cache_entry_mark_for_removal().
char* fname |
Filename for this object within the storage_dir_t
Definition at line 41 of file conscache.c.
Referenced by consensus_cache_entry_map().
consensus_cache_t* in_cache |
Pointer to the cache that includes this entry (if any).
Definition at line 46 of file conscache.c.
config_line_t* labels |
Labels associated with this object. Immutable once the object is created.
Definition at line 44 of file conscache.c.
Referenced by consensus_cache_entry_get_labels(), and consensus_cache_entry_get_value().
uint32_t magic |
Must be set to CCE_MAGIC
Definition at line 33 of file conscache.c.
tor_mmap_t* map |
mmaped contents of the underlying file. May be NULL
Definition at line 52 of file conscache.c.
Referenced by consensus_cache_entry_map().
int32_t refcnt |
Reference count.
Definition at line 35 of file conscache.c.
unsigned release_aggressively |
If true, we intend to unmap this file as soon as we're done with it.
Definition at line 38 of file conscache.c.
Referenced by consensus_cache_entry_mark_for_aggressive_release().
time_t unused_since |
Since what time has this object been mapped into RAM, but with the cache being the only having a reference to it?
Definition at line 50 of file conscache.c.
Referenced by consensus_cache_entry_map(), and consensus_cache_entry_unmap().