fix boolean check to be easier to read

This commit is contained in:
Dane Springmeyer 2013-05-21 12:55:08 -07:00
parent 49933d7d0f
commit 8478fdc217

View file

@ -126,7 +126,9 @@ csv_datasource::csv_datasource(parameters const& params)
std::ifstream in(filename_.c_str(),std::ios_base::in | std::ios_base::binary);
#endif
if (!in.is_open())
{
throw mapnik::datasource_exception("CSV Plugin: could not open: '" + filename_ + "'");
}
parse_csv(in,escape_, separator_, quote_);
in.close();
}
@ -864,7 +866,7 @@ void csv_datasource::parse_csv(T & stream,
}
}
}
if (!feature_count > 0)
if (feature_count < 1)
{
MAPNIK_LOG_ERROR(csv) << "CSV Plugin: could not parse any lines of data";
}