![]() |
Nilorea Library
C utilities for networking, threading, graphics
|
Functions | |
size_t | CompressData (unsigned char *abSrc, size_t nLenSrc, unsigned char *abDst, size_t nLenDst) |
size_t | GetMaxCompressedLen (size_t nLenSrc) |
Return the maximum compressed size. | |
size_t | UncompressData (unsigned char *abSrc, size_t nLenSrc, unsigned char *abDst, size_t nLenDst) |
Uncompress a string to another. | |
N_STR * | unzip_nstr (N_STR *src) |
return an uncompressed version of src | |
N_STR * | zip_nstr (N_STR *src) |
return a compressed version of src | |
size_t CompressData | ( | unsigned char * | abSrc, |
size_t | nLenSrc, | ||
unsigned char * | abDst, | ||
size_t | nLenDst | ||
) |
size_t GetMaxCompressedLen | ( | size_t | nLenSrc | ) |
Return the maximum compressed size.
nLenSrc |
Definition at line 24 of file n_zlib.c.
Referenced by zip_nstr().
size_t UncompressData | ( | unsigned char * | abSrc, |
size_t | nLenSrc, | ||
unsigned char * | abDst, | ||
size_t | nLenDst | ||
) |
Uncompress a string to another.
abSrc | source string |
nLenSrc | size of source string |
abDst | destination string |
nLenDst | destination length |
Definition at line 94 of file n_zlib.c.
References __n_assert, LOG_ERR, and n_log.
Referenced by unzip_nstr().
return an uncompressed version of src
src | The source string |
Definition at line 199 of file n_zlib.c.
References __n_assert, N_STR::data, free_nstr, N_STR::length, LOG_DEBUG, LOG_ERR, n_log, new_nstr(), UncompressData(), and N_STR::written.
return a compressed version of src
src | The source string |
Definition at line 148 of file n_zlib.c.
References __n_assert, N_STR::data, free_nstr, GetMaxCompressedLen(), N_STR::length, LOG_DEBUG, LOG_ERR, n_log, new_nstr(), and N_STR::written.