ICU-13356 gennorm2 crashes if the input file contains blank lines.

X-SVN-Rev: 40414
This commit is contained in:
Jeff Genovy 2017-09-14 19:04:20 +00:00
parent 03f431d30d
commit fc78f45dd9

View file

@ -235,6 +235,9 @@ void parseFile(std::ifstream &f, Normalizer2DataBuilder &builder) {
std::string lineString;
uint32_t startCP, endCP;
while(std::getline(f, lineString)) {
if (lineString.empty()) {
continue; // skip empty lines.
}
#if (U_CPLUSPLUS_VERSION >= 11)
char *line = &lineString.front();
#else