uncompress — Un-compresses the data.
Libz.lib
#include <zlib.h>
int uncompress(Bytef * dest, uLongf * destLen, const Bytef * source, uLong sourceLen);
The uncompress() function shall attempt to uncompress sourceLen bytes of data in the buffer source, placing the result in the buffer dest.
On entry, destLen should point to
a value describing
the size of the dest buffer. The
application should ensure that this value is large enough to hold
the entire uncompressed data.
Note: The LSB does not describe any mechanism by which a compressor can communicate the size required to the uncompressor.
To uncompress the compressed string in compr:
#include <stdio.h> { |
Output
uncompr contains uncompressed string.
|
On error, uncompress() shall return a value as described below:
Z_BUF_ERROR |
The buffer dest was not large enough to hold the uncompressed data. |
|
Z_MEM_ERROR |
Insufficient memory. |
|
Z_DATA_ERROR |
The compressed data (referenced by source) was corrupted. |
For additional information or queries on this page send feedback
© 2008 Nokia Corporation. All rights reserved. This documentation can be used in the connection with this Product to help and support the user. |