gravatar
deba@inf.elte.hu
deba@inf.elte.hu
Fix skipSection() function (ticket #193)
0 1 0
default
1 file changed with 8 insertions and 0 deletions:
↑ Collapse diff ↑
Show white space 16 line context
... ...
@@ -865,18 +865,20 @@
865 865
      return static_cast<bool>(*_is);
866 866
    }
867 867

	
868 868
    void skipSection() {
869 869
      char c;
870 870
      while (readSuccess() && line >> c && c != '@') {
871 871
        readLine();
872 872
      }
873
      if (readSuccess()) {
873 874
      line.putback(c);
874 875
    }
876
    }
875 877

	
876 878
    void readNodes() {
877 879

	
878 880
      std::vector<int> map_index(_node_maps.size());
879 881
      int map_num, label_index;
880 882

	
881 883
      char c;
882 884
      if (!readLine() || !(line >> c) || c == '@') {
... ...
@@ -1694,18 +1696,20 @@
1694 1696
      return static_cast<bool>(*_is);
1695 1697
    }
1696 1698

	
1697 1699
    void skipSection() {
1698 1700
      char c;
1699 1701
      while (readSuccess() && line >> c && c != '@') {
1700 1702
        readLine();
1701 1703
      }
1704
      if (readSuccess()) {
1702 1705
      line.putback(c);
1703 1706
    }
1707
    }
1704 1708

	
1705 1709
    void readNodes() {
1706 1710

	
1707 1711
      std::vector<int> map_index(_node_maps.size());
1708 1712
      int map_num, label_index;
1709 1713

	
1710 1714
      char c;
1711 1715
      if (!readLine() || !(line >> c) || c == '@') {
... ...
@@ -2221,18 +2225,20 @@
2221 2225
      return static_cast<bool>(*_is);
2222 2226
    }
2223 2227

	
2224 2228
    void skipSection() {
2225 2229
      char c;
2226 2230
      while (readSuccess() && line >> c && c != '@') {
2227 2231
        readLine();
2228 2232
      }
2233
      if (readSuccess()) {
2229 2234
      line.putback(c);
2230 2235
    }
2236
    }
2231 2237

	
2232 2238
  public:
2233 2239

	
2234 2240

	
2235 2241
    /// \name Execution of the reader
2236 2242
    /// @{
2237 2243

	
2238 2244
    /// \brief Start the batch processing
... ...
@@ -2562,18 +2568,20 @@
2562 2568
      return static_cast<bool>(*_is);
2563 2569
    }
2564 2570

	
2565 2571
    void skipSection() {
2566 2572
      char c;
2567 2573
      while (readSuccess() && line >> c && c != '@') {
2568 2574
        readLine();
2569 2575
      }
2576
      if (readSuccess()) {
2570 2577
      line.putback(c);
2571 2578
    }
2579
    }
2572 2580

	
2573 2581
    void readMaps(std::vector<std::string>& maps) {
2574 2582
      char c;
2575 2583
      if (!readLine() || !(line >> c) || c == '@') {
2576 2584
        if (readSuccess() && line) line.putback(c);
2577 2585
        return;
2578 2586
      }
2579 2587
      line.putback(c);
0 comments (0 inline)