Fix qmake's sed functionality for input containing CR+LF newlines
QTextStream, reading a file with CR+LF newlines from an stdio FILE handle that was opened without "b", will always return false in atEnd(). Changing the open mode from "r" to "rb" works around the issue. Task-number: QTBUG-80443 Change-Id: Ib2eafc0c4c6a6d2bcaeea3036474549d2d9e1511 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
This commit is contained in:
parent
92cf38018a
commit
83df5c71e6
@ -154,7 +154,7 @@ static int doSed(int argc, char **argv)
|
||||
FILE *f;
|
||||
if (!strcmp(inFile, "-")) {
|
||||
f = stdin;
|
||||
} else if (!(f = fopen(inFile, "r"))) {
|
||||
} else if (!(f = fopen(inFile, "rb"))) {
|
||||
perror(inFile);
|
||||
return 1;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user