mirror of
https://github.com/zint/zint
synced 2024-11-16 20:57:25 +13:00
nRead is not used on error
This commit is contained in:
parent
7ca22f24a4
commit
bfb4d3284b
@ -1241,7 +1241,6 @@ int ZBarcode_Encode_File(struct zint_symbol *symbol, char *filename) {
|
||||
n = fread(buffer + nRead, 1, fileLen - nRead, file);
|
||||
if (ferror(file)) {
|
||||
strcpy(symbol->errtxt, strerror(errno));
|
||||
nRead = 0;
|
||||
return ZINT_ERROR_INVALID_DATA;
|
||||
}
|
||||
nRead += n;
|
||||
|
Loading…
Reference in New Issue
Block a user