The local variable record is hiding a field from type CSVParser.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/csv/trunk@1558888 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
cb5de89971
commit
b3553addb7
|
@ -330,9 +330,9 @@ public final class CSVParser implements Iterable<CSVRecord>, Closeable {
|
||||||
String[] header = null;
|
String[] header = null;
|
||||||
if (formatHeader.length == 0) {
|
if (formatHeader.length == 0) {
|
||||||
// read the header from the first line of the file
|
// read the header from the first line of the file
|
||||||
final CSVRecord record = this.nextRecord();
|
final CSVRecord nextRecord = this.nextRecord();
|
||||||
if (record != null) {
|
if (nextRecord != null) {
|
||||||
header = record.values();
|
header = nextRecord.values();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (this.format.getSkipHeaderRecord()) {
|
if (this.format.getSkipHeaderRecord()) {
|
||||||
|
|
Loading…
Reference in New Issue