From: Nick Terrell Date: Fri, 31 Mar 2017 22:20:50 +0000 (-0700) Subject: Clean up default sparse logic X-Git-Tag: v1.2.0^2~68^2^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F642%2Fhead;p=thirdparty%2Fzstd.git Clean up default sparse logic --- diff --git a/programs/fileio.c b/programs/fileio.c index 87871ae01..78fb9a268 100644 --- a/programs/fileio.c +++ b/programs/fileio.c @@ -227,8 +227,8 @@ static FILE* FIO_openDstFile(const char* dstFileName) DISPLAYLEVEL(4, "Sparse File Support is automatically disabled on stdout ; try --sparse \n"); } } else { - if (ZSTD_SPARSE_DEFAULT == 0 && g_sparseFileSupport == 1) { - g_sparseFileSupport = 0; + if (g_sparseFileSupport == 1) { + g_sparseFileSupport = ZSTD_SPARSE_DEFAULT; } if (!g_overwrite && strcmp (dstFileName, nulmark)) { /* Check if destination file already exists */ f = fopen( dstFileName, "rb" );