# HG changeset patch # User Balazs Dezso # Date 2008-06-16 18:19:07 # Node ID c94a80f38d7fcde5fb63e26409be118d0afbefe4 # Parent 02f4d5d9bfd743e5737320a9f40fa964332bf953 Clarifying the usage of skipSection diff --git a/lemon/lgf_reader.h b/lemon/lgf_reader.h --- a/lemon/lgf_reader.h +++ b/lemon/lgf_reader.h @@ -1139,9 +1139,9 @@ line_num = 0; readLine(); + skipSection(); while (readSuccess()) { - skipSection(); try { char c; std::string section, caption; @@ -1178,11 +1178,9 @@ if (it != _sections.end()) { extra_sections.insert(section); it->second->process(*_is, line_num); - readLine(); - } else { - readLine(); - skipSection(); } + readLine(); + skipSection(); } } catch (DataFormatError& error) { error.line(line_num); @@ -1981,9 +1979,9 @@ line_num = 0; readLine(); + skipSection(); while (readSuccess()) { - skipSection(); try { char c; std::string section, caption; @@ -2020,11 +2018,9 @@ if (it != _sections.end()) { extra_sections.insert(section); it->second->process(*_is, line_num); - readLine(); - } else { - readLine(); - skipSection(); } + readLine(); + skipSection(); } } catch (DataFormatError& error) { error.line(line_num);