MCPcopy Create free account
hub / github.com/Meituan-Dianping/SQLAdvisor / _tr_stored_block

Function _tr_stored_block

zlib/trees.c:867–879  ·  view source on GitHub ↗

=========================================================================== * Send a stored block */

(s, buf, stored_len, eof)

Source from the content-addressed store, hash-verified

865 * Send a stored block
866 */
867void _tr_stored_block(s, buf, stored_len, eof)
868 deflate_state *s;
869 charf *buf; /* input block */
870 ulg stored_len; /* length of input block */
871 int eof; /* true if this is the last block for a file */
872{
873 send_bits(s, (STORED_BLOCK<<1)+eof, 3); /* send block type */
874#ifdef DEBUG
875 s->compressed_len = (s->compressed_len + 3 + 7) & (ulg)~7L;
876 s->compressed_len += (stored_len + 4) << 3;
877#endif
878 copy_block(s, buf, (unsigned)stored_len, 1); /* with header */
879}
880
881/* ===========================================================================
882 * Send one empty static block to give enough lookahead for inflate.

Callers 2

trees.cFile · 0.85
deflateFunction · 0.85

Calls 2

send_bitsFunction · 0.85
copy_blockFunction · 0.85

Tested by

no test coverage detected