summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--programs/lz4cli.c2
-rw-r--r--programs/lz4io.c12
-rw-r--r--programs/lz4io.h6
3 files changed, 10 insertions, 10 deletions
diff --git a/programs/lz4cli.c b/programs/lz4cli.c
index 6ed98c0..a6f4b4e 100644
--- a/programs/lz4cli.c
+++ b/programs/lz4cli.c
@@ -393,7 +393,7 @@ int main(int argc, const char** argv)
case 'c': forceStdout=1; output_filename=stdoutmark; displayLevel=1; break;
/* Test integrity */
- case 't': decode=1; LZ4IO_setPassThrough(0); output_filename=nulmark; break;
+ case 't': decode=1; LZ4IO_setTestMode(1); output_filename=nulmark; break;
/* Overwrite */
case 'f': LZ4IO_setOverwrite(1); break;
diff --git a/programs/lz4io.c b/programs/lz4io.c
index 3a85830..2f64561 100644
--- a/programs/lz4io.c
+++ b/programs/lz4io.c
@@ -136,7 +136,7 @@ static clock_t g_time = 0;
* Local Parameters
**************************************/
static int g_overwrite = 1;
-static int g_passThrough = 1;
+static int g_testMode = 0;
static int g_blockSizeId = LZ4IO_BLOCKSIZEID_DEFAULT;
static int g_blockChecksum = 0;
static int g_streamChecksum = 1;
@@ -185,11 +185,11 @@ int LZ4IO_setOverwrite(int yes)
return g_overwrite;
}
-/* Default setting : passThrough = 1; return : passThrough mode (0/1) */
-int LZ4IO_setPassThrough(int yes)
+/* Default setting : testMode = 0; return : testMode (0/1) */
+int LZ4IO_setTestMode(int yes)
{
- g_passThrough = (yes!=0);
- return g_passThrough;
+ g_testMode = (yes!=0);
+ return g_testMode;
}
/* blockSizeID : valid values : 4-5-6-7 */
@@ -916,7 +916,7 @@ static unsigned long long selectDecoder(dRess_t ress, FILE* finput, FILE* foutpu
EXTENDED_FORMAT; /* macro extension for custom formats */
default:
if (nbCalls == 1) { /* just started */
- if (g_passThrough && g_overwrite)
+ if (!g_testMode && g_overwrite)
return LZ4IO_passThrough(finput, foutput, MNstore);
EXM_THROW(44,"Unrecognized header : file cannot be decoded"); /* Wrong magic number at the beginning of 1st stream */
}
diff --git a/programs/lz4io.h b/programs/lz4io.h
index 8109298..bf076ee 100644
--- a/programs/lz4io.h
+++ b/programs/lz4io.h
@@ -63,9 +63,9 @@ int LZ4IO_decompressMultipleFilenames(const char** inFileNamesTable, int ifntSiz
return : overwrite mode (0/1) */
int LZ4IO_setOverwrite(int yes);
-/* Default setting : passThrough = 1;
- return : passThrough mode (0/1) */
-int LZ4IO_setPassThrough(int yes);
+/* Default setting : testMode = 0;
+ return : testMode (0/1) */
+int LZ4IO_setTestMode(int yes);
/* blockSizeID : valid values : 4-5-6-7
return : -1 if error, blockSize if OK */