mirror of
https://git.code.sf.net/p/zint/code
synced 2025-12-18 02:17:06 +00:00
Fix batch bugs: 1) interpretation of former code included in next if shorter, wrong eof detection issed wrong warning
This commit is contained in:
@@ -223,7 +223,12 @@ int batch_process(struct zint_symbol *symbol, char *filename)
|
||||
}
|
||||
|
||||
do {
|
||||
character = fgetc(file);
|
||||
int intChar;
|
||||
intChar = fgetc(file);
|
||||
if (intChar == EOF) {
|
||||
break;
|
||||
}
|
||||
character = (unsigned char) intChar;
|
||||
if(character == '\n') {
|
||||
if(buffer[posn - 1] == '\r') {
|
||||
/* CR+LF - assume Windows formatting and remove CR */
|
||||
|
||||
Reference in New Issue
Block a user