Add NULL check for dict
parent
8ea219d8c6
commit
5333e41ab3
|
@ -1298,8 +1298,8 @@ FIO_compressFilename_srcFile(FIO_prefs_t* const prefs,
|
|||
return 1;
|
||||
}
|
||||
|
||||
/* ensure src is not the same as dict */
|
||||
if (UTIL_isSameFile(srcFileName, ress.dictFileName)) {
|
||||
/* ensure src is not the same as dict (if present) */
|
||||
if (ress.dictFileName != NULL && UTIL_isSameFile(srcFileName, ress.dictFileName)) {
|
||||
DISPLAYLEVEL(1, "zstd: cannot use %s as an input file and dictionary \n", srcFileName);
|
||||
return 1;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue