Revision: 68883
          http://sourceforge.net/p/brlcad/code/68883
Author:   starseeker
Date:     2016-09-21 23:32:50 +0000 (Wed, 21 Sep 2016)
Log Message:
-----------
skip comment lines

Modified Paths:
--------------
    brlcad/trunk/src/conv/dyn-g.cpp

Modified: brlcad/trunk/src/conv/dyn-g.cpp
===================================================================
--- brlcad/trunk/src/conv/dyn-g.cpp     2016-09-21 22:59:09 UTC (rev 68882)
+++ brlcad/trunk/src/conv/dyn-g.cpp     2016-09-21 23:32:50 UTC (rev 68883)
@@ -108,6 +108,7 @@
     part->heading = NULL;
     part->PID = -1;
     while (std::getline(infile, line) && !end_part) {
+       if (line.c_str()[0] == '$') continue;
        if (line_cnt == 2 || line.c_str()[0] == '*') {
            end_part = 1;
            break;
@@ -143,6 +144,7 @@
     infile.clear();
     infile.seekg(offset);
     while (std::getline(infile, line) && !end_nodes) {
+       if (line.c_str()[0] == '$') continue;
        if (line.c_str()[0] == '*') {
            end_nodes = 1;
            break;
@@ -193,6 +195,7 @@
     infile.seekg(offset);
     char *endptr;
     while (std::getline(infile, line) && !end_es) {
+       if (line.c_str()[0] == '$') continue;
        if (line.c_str()[0] == '*') {
            end_es = 1;
            break;
@@ -223,6 +226,9 @@
                std::string remainder = line.substr(i,incr);
                if (remainder.find_first_not_of(" \t\n\v\f\r") == 
std::string::npos) {
                    std::getline(infile, line);
+                   while (line.c_str()[0] == '$' && !line.c_str()[0] == '$') {
+                       std::getline(infile, line);
+                   };
                    i = 0;
                    col_cnt = 0;
                    next_line = 1;
@@ -259,6 +265,7 @@
     infile.clear();
     infile.seekg(offset);
     while (std::getline(infile, line) && !end_es) {
+       if (line.c_str()[0] == '$') continue;
        if (line.c_str()[0] == '*') {
            end_es = 1;
            break;
@@ -443,6 +450,7 @@
     std::set<int> element_shells;
     std::set<int> element_solids;
     while (std::getline(infile, line)) {
+       if (line.c_str()[0] == '$') continue;
        if (line.c_str()[0] == '*') {
            size_t endpos = line.find_last_not_of(" \t");
            std::string keyword = line.substr(1,endpos+1);

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
_______________________________________________
BRL-CAD Source Commits mailing list
brlcad-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to