Stop memcpy'ing uncompressed consensuses when making diffs

This commit is contained in:
Nick Mathewson
2018-09-11 10:09:12 -04:00
parent 5595b21227
commit e014b72b73
4 changed files with 56 additions and 32 deletions
+3 -2
View File
@@ -68,8 +68,9 @@ STATIC consensus_cache_entry_t *cdm_cache_lookup_consensus(
STATIC int cdm_entry_get_sha3_value(uint8_t *digest_out,
consensus_cache_entry_t *ent,
const char *label);
STATIC int uncompress_or_copy(char **out, size_t *outlen,
consensus_cache_entry_t *ent);
STATIC int uncompress_or_set_ptr(const char **out, size_t *outlen,
char **owned_out,
consensus_cache_entry_t *ent);
#endif /* defined(CONSDIFFMGR_PRIVATE) */
#endif /* !defined(TOR_CONSDIFFMGR_H) */