]> git.ipfire.org Git - thirdparty/zstd.git/commitdiff
Expose ZSTD_CLEVEL_DEFAULT and update documentation
authorDuc Ngo <duc@fb.com>
Fri, 8 Jun 2018 18:29:51 +0000 (11:29 -0700)
committerDuc Ngo <duc@fb.com>
Fri, 8 Jun 2018 18:33:44 +0000 (11:33 -0700)
lib/compress/zstd_compress.c
lib/zstd.h

index e0c29ac44cce201e40a9e67217f5a48cac31bd28..ba70308df4af0543ef8b29987c59b4df405b5f41 100644 (file)
@@ -8,15 +8,6 @@
  * You may select, at your option, one of the above-listed licenses.
  */
 
-
-/*-*************************************
-*  Tuning parameters
-***************************************/
-#ifndef ZSTD_CLEVEL_DEFAULT
-#  define ZSTD_CLEVEL_DEFAULT 3
-#endif
-
-
 /*-*************************************
 *  Dependencies
 ***************************************/
index 8f42ff81b97d812e0390c8d4e36c39140c697538..e49cc815ef0f969763d5b921febdd9fc234f81cd 100644 (file)
@@ -35,6 +35,14 @@ extern "C" {
 #endif
 
 
+/*-*************************************
+*  Tuning parameters
+***************************************/
+#ifndef ZSTD_CLEVEL_DEFAULT
+#  define ZSTD_CLEVEL_DEFAULT 3
+#endif
+
+
 /*******************************************************************************************************
   Introduction
 
@@ -949,7 +957,7 @@ typedef enum {
     /* compression parameters */
     ZSTD_p_compressionLevel=100, /* Update all compression parameters according to pre-defined cLevel table
                               * Default level is ZSTD_CLEVEL_DEFAULT==3.
-                              * Special: value 0 means "do not change cLevel".
+                              * Special: value 0 means default, which is controlled by ZSTD_CLEVEL_DEFAULT.
                               * Note 1 : it's possible to pass a negative compression level by casting it to unsigned type.
                               * Note 2 : setting a level sets all default values of other compression parameters.
                               * Note 3 : setting compressionLevel automatically updates ZSTD_p_compressLiterals. */