1
0
Fork 0

Jon Berndt:

I had inadvertently terminated a data line when reaching a tab character after
initial data was supplied. I tested the lightning file and it now appears to
read in correctly.
This commit is contained in:
ehofman 2006-03-22 13:32:32 +00:00
parent a04aad7a99
commit 746fe74838

View file

@ -407,12 +407,9 @@ void Element::AddAttribute(string name, string value)
void Element::AddData(string d) void Element::AddData(string d)
{ {
int string_end=-1;
int string_start = d.find_first_not_of(" \t"); int string_start = d.find_first_not_of(" \t");
if (string_start > 0) { if (string_start > 0) {
d.erase(0,string_start); d.erase(0,string_start);
string_end = d.find_first_of(" \t");
if (string_end > 0) d.erase(string_end,d.size()-string_end);
} }
data_lines.push_back(d); data_lines.push_back(d);
} }