summaryrefslogtreecommitdiffstats
path: root/lib/lz4hc.h
diff options
context:
space:
mode:
authorYann Collet <cyan@fb.com>2019-04-09 20:55:42 (GMT)
committerYann Collet <cyan@fb.com>2019-04-09 20:55:42 (GMT)
commit14c71dfa9cc7161e1283e27bc688fd2bbeb637a2 (patch)
tree1cb94bbf24665abc35f72e9fd30663f9228740d8 /lib/lz4hc.h
parent5ef4f3ce913dae19f6bcd065a2b231c5461e4233 (diff)
downloadlz4-14c71dfa9cc7161e1283e27bc688fd2bbeb637a2.zip
lz4-14c71dfa9cc7161e1283e27bc688fd2bbeb637a2.tar.gz
lz4-14c71dfa9cc7161e1283e27bc688fd2bbeb637a2.tar.bz2
modified LZ4_initStreamHC() to look like LZ4_initStream()
it is now a pure initializer, for statically allocated states. It can initialize any memory area, and because of this, requires size.
Diffstat (limited to 'lib/lz4hc.h')
-rw-r--r--lib/lz4hc.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/lz4hc.h b/lib/lz4hc.h
index fbf4518..445c126 100644
--- a/lib/lz4hc.h
+++ b/lib/lz4hc.h
@@ -265,7 +265,7 @@ union LZ4_streamHC_u {
* Static allocation shall only be used in combination with static linking.
*/
-LZ4LIB_API void LZ4_initStreamHC (void* streamHCPtr, int compressionLevel); /* v1.9.0+ */
+LZ4LIB_API LZ4_streamHC_t* LZ4_initStreamHC (void* buffer, size_t size);
/*-************************************
@@ -299,7 +299,7 @@ LZ4_DEPRECATED("use LZ4_freeStreamHC() instead") LZ4LIB_API int LZ4_freeHC (
LZ4_DEPRECATED("use LZ4_compress_HC_continue() instead") LZ4LIB_API int LZ4_compressHC2_continue (void* LZ4HC_Data, const char* source, char* dest, int inputSize, int compressionLevel);
LZ4_DEPRECATED("use LZ4_compress_HC_continue() instead") LZ4LIB_API int LZ4_compressHC2_limitedOutput_continue (void* LZ4HC_Data, const char* source, char* dest, int inputSize, int maxOutputSize, int compressionLevel);
LZ4_DEPRECATED("use LZ4_createStreamHC() instead") LZ4LIB_API int LZ4_sizeofStreamStateHC(void);
-LZ4_DEPRECATED("use LZ4_resetStreamHC() instead") LZ4LIB_API int LZ4_resetStreamStateHC(void* state, char* inputBuffer);
+LZ4_DEPRECATED("use LZ4_initStreamHC() instead") LZ4LIB_API int LZ4_resetStreamStateHC(void* state, char* inputBuffer);
/* LZ4_resetStreamHC() is now replaced by LZ4_initStreamHC().
@@ -310,7 +310,7 @@ LZ4_DEPRECATED("use LZ4_resetStreamHC() instead") LZ4LIB_API int LZ4_resetStr
* It is recommended to switch to LZ4_initStreamHC().
* LZ4_resetStreamHC() will generate deprecation warnings in a future version.
*/
-LZ4LIB_API void LZ4_resetStreamHC (LZ4_streamHC_t* streamHCPtr, int compressionLevel);
+//LZ4LIB_API void LZ4_resetStreamHC (LZ4_streamHC_t* streamHCPtr, int compressionLevel);
#if defined (__cplusplus)