* independent siphashes rather than messing around with bit-shifts. The
* approach here is probably more sound, and we should prefer it if&when we
* unify the implementations.
- **/
+ */
struct address_set_t {
/** siphash keys to make N_HASHES independent hashes for each address. */
}
/**
- * Release all storage associated with <b>set</b>
+ * Release all storage associated with <b>set</b>.
*/
void
address_set_free(address_set_t *set)
}
/**
- * Return true if <b>addr</b> if a member of <b>set</b>. (And probably,
+ * Return true if <b>addr</b> is a member of <b>set</b>. (And probably,
* return false if <b>addr</b> is not a member of set.)
*/
int
* circuit to the same rendezvous point at the same time. */
circ->hs_service_side_rend_circ_has_been_relaunched = 1;
- /* Legacy service don't have a hidden service ident. */
+ /* Legacy services don't have a hidden service ident. */
if (circ->hs_ident) {
retry_service_rendezvous_point(circ);
} else {
/** Free the replaycache r and all of its entries.
*/
-
void
replaycache_free_(replaycache_t *r)
{
* for entries to age out and interval is the time after which the cache
* should be scrubbed for old entries.
*/
-
replaycache_t *
replaycache_new(time_t horizon, time_t interval)
{
return r;
}
-/** See documentation for replaycache_add_and_test()
+/** See documentation for replaycache_add_and_test().
*/
-
STATIC int
replaycache_add_and_test_internal(
time_t present, replaycache_t *r, const void *data, size_t len,
return rv;
}
-/** See documentation for replaycache_scrub_if_needed()
+/** See documentation for replaycache_scrub_if_needed().
*/
-
STATIC void
replaycache_scrub_if_needed_internal(time_t present, replaycache_t *r)
{
* and the function will return 1 if it was already seen within the cache's
* horizon, or 0 otherwise.
*/
-
int
replaycache_add_and_test(replaycache_t *r, const void *data, size_t len)
{
/** Like replaycache_add_and_test(), but if it's a hit also return the time
* elapsed since this digest was last seen.
*/
-
int
replaycache_add_test_and_elapsed(
replaycache_t *r, const void *data, size_t len, time_t *elapsed)
/** Scrub aged entries out of r if sufficiently long has elapsed since r was
* last scrubbed.
*/
-
void
replaycache_scrub_if_needed(replaycache_t *r)
{