added ZSTDMT_createCCtx_advanced()

make it possible to use custom allocators
This commit is contained in:
Yann Collet
2017-05-30 16:12:06 -07:00
parent f45ca527a1
commit 44e45e8423
6 changed files with 118 additions and 66 deletions
+2
View File
@@ -338,6 +338,8 @@ size_t ZSTD_decompressStream(ZSTD_DStream* zds, ZSTD_outBuffer* output, ZSTD_inB
<h3>Custom memory allocation functions</h3><pre></pre><b><pre>typedef void* (*ZSTD_allocFunction) (void* opaque, size_t size);
typedef void (*ZSTD_freeFunction) (void* opaque, void* address);
typedef struct { ZSTD_allocFunction customAlloc; ZSTD_freeFunction customFree; void* opaque; } ZSTD_customMem;
</b>/* use this constant to defer to stdlib's functions */<b>
static const ZSTD_customMem ZSTD_defaultCMem = { NULL, NULL, NULL};
</pre></b><BR>
<a name="Chapter12"></a><h2>Frame size functions</h2><pre></pre>