MCPcopy Create free account
hub / github.com/RsyncProject/rsync / _tr_init

Function _tr_init

zlib/trees.c:378–400  ·  view source on GitHub ↗

=========================================================================== * Initialize the tree data structures for a new zlib stream. */

Source from the content-addressed store, hash-verified

376 * Initialize the tree data structures for a new zlib stream.
377 */
378void ZLIB_INTERNAL _tr_init(deflate_state *s)
379{
380 tr_static_init();
381
382 s->l_desc.dyn_tree = s->dyn_ltree;
383 s->l_desc.stat_desc = &static_l_desc;
384
385 s->d_desc.dyn_tree = s->dyn_dtree;
386 s->d_desc.stat_desc = &static_d_desc;
387
388 s->bl_desc.dyn_tree = s->bl_tree;
389 s->bl_desc.stat_desc = &static_bl_desc;
390
391 s->bi_buf = 0;
392 s->bi_valid = 0;
393#ifdef DEBUG
394 s->compressed_len = 0L;
395 s->bits_sent = 0L;
396#endif
397
398 /* Initialize the first block of the first file: */
399 init_block(s);
400}
401
402/* ===========================================================================
403 * Initialize a new block.

Callers 1

deflateResetKeepFunction · 0.85

Calls 2

tr_static_initFunction · 0.85
init_blockFunction · 0.85

Tested by

no test coverage detected