]> andersk Git - openssh.git/blame - compress.h
- OpenBSD CVS updates.
[openssh.git] / compress.h
CommitLineData
8efc0c15 1/*
6ae2364d 2 *
5260325f 3 * compress.h
6ae2364d 4 *
5260325f 5 * Author: Tatu Ylonen <ylo@cs.hut.fi>
6ae2364d 6 *
5260325f 7 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
8 * All rights reserved
6ae2364d 9 *
5260325f 10 * Created: Wed Oct 25 22:12:46 1995 ylo
6ae2364d 11 *
5260325f 12 * Interface to packet compression for ssh.
6ae2364d 13 *
5260325f 14 */
8efc0c15 15
16/* RCSID("$Id$"); */
17
18#ifndef COMPRESS_H
19#define COMPRESS_H
20
aa3378df 21/*
22 * Initializes compression; level is compression level from 1 to 9 (as in
23 * gzip).
24 */
5260325f 25void buffer_compress_init(int level);
8efc0c15 26
27/* Frees any data structures allocated by buffer_compress_init. */
5260325f 28void buffer_compress_uninit();
8efc0c15 29
aa3378df 30/*
31 * Compresses the contents of input_buffer into output_buffer. All packets
32 * compressed using this function will form a single compressed data stream;
33 * however, data will be flushed at the end of every call so that each
34 * output_buffer can be decompressed independently (but in the appropriate
35 * order since they together form a single compression stream) by the
36 * receiver. This appends the compressed data to the output buffer.
37 */
5260325f 38void buffer_compress(Buffer * input_buffer, Buffer * output_buffer);
8efc0c15 39
aa3378df 40/*
41 * Uncompresses the contents of input_buffer into output_buffer. All packets
42 * uncompressed using this function will form a single compressed data
43 * stream; however, data will be flushed at the end of every call so that
44 * each output_buffer. This must be called for the same size units that the
45 * buffer_compress was called, and in the same order that buffers compressed
46 * with that. This appends the uncompressed data to the output buffer.
47 */
5260325f 48void buffer_uncompress(Buffer * input_buffer, Buffer * output_buffer);
8efc0c15 49
5260325f 50#endif /* COMPRESS_H */
This page took 0.062778 seconds and 5 git commands to generate.