fix for getline usage with newer compilers
This commit is contained in:
@@ -238,7 +238,7 @@ public:
|
||||
ostringstream field;
|
||||
char prev = FIELD_SEPARATOR;
|
||||
bool empty = true, read = false;
|
||||
while (getline(ifs, line) != 0) {
|
||||
while (getline(ifs, line)) {
|
||||
read = true;
|
||||
lineNo++;
|
||||
trim(line);
|
||||
|
||||
@@ -408,7 +408,7 @@ int main()
|
||||
string item;
|
||||
vector<string> entries;
|
||||
|
||||
while (getline(isstr, item, FIELD_SEPARATOR) != 0)
|
||||
while (getline(isstr, item, FIELD_SEPARATOR))
|
||||
entries.push_back(item);
|
||||
|
||||
if (fields != NULL) {
|
||||
|
||||
@@ -145,7 +145,7 @@ int main()
|
||||
size_t pos = 0;
|
||||
string token;
|
||||
istringstream stream(check[2]);
|
||||
while (getline(stream, token, VALUE_SEPARATOR) != 0) {
|
||||
while (getline(stream, token, VALUE_SEPARATOR)) {
|
||||
if (pos >= mstrs.size())
|
||||
mstrs.resize(pos+1);
|
||||
else if (mstrs[pos]!=NULL)
|
||||
@@ -161,7 +161,7 @@ int main()
|
||||
pos = 0;
|
||||
stream.str(check[3]);
|
||||
stream.clear();
|
||||
while (getline(stream, token, VALUE_SEPARATOR) != 0) {
|
||||
while (getline(stream, token, VALUE_SEPARATOR)) {
|
||||
if (pos >= sstrs.size())
|
||||
sstrs.resize(pos+1);
|
||||
else if (sstrs[pos]!=NULL)
|
||||
|
||||
Reference in New Issue
Block a user