# HG changeset patch # User Ingo Weinzierl # Date 1261048485 0 # Node ID da2da7bb1aa1fbca6c34b71c03f88aec09bf4143 # Parent 0b813ae171736a5dd6ed1fa10cc8ae0b1ddc36be Fixed a bug in DefaultResult when querying an index out of bounds. geo-backend/trunk@445 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r 0b813ae17173 -r da2da7bb1aa1 geo-backend/ChangeLog --- a/geo-backend/ChangeLog Tue Dec 15 10:02:24 2009 +0000 +++ b/geo-backend/ChangeLog Thu Dec 17 11:14:45 2009 +0000 @@ -1,3 +1,8 @@ +2009-12-17 Ingo Weinzierl + + * src/main/java/de/intevation/gnv/geobackend/base/DefaultResult.java: + Fixed bug in DefaultResult when querying an index out of bounds. + 2009-12-15 Tim Englich * src/main/java/de/intevation/gnv/geobackend/sde/datasources/ArcSDEStatement.java (executeQuery): diff -r 0b813ae17173 -r da2da7bb1aa1 geo-backend/src/main/java/de/intevation/gnv/geobackend/base/DefaultResult.java --- a/geo-backend/src/main/java/de/intevation/gnv/geobackend/base/DefaultResult.java Tue Dec 15 10:02:24 2009 +0000 +++ b/geo-backend/src/main/java/de/intevation/gnv/geobackend/base/DefaultResult.java Thu Dec 17 11:14:45 2009 +0000 @@ -87,7 +87,10 @@ * @see de.intevation.gnv.geobackend.base.Result#getInteger(java.lang.String) */ public Integer getInteger(String columnName) { - return getInteger(resultDescriptor.getColumnIndex(columnName)); + int idx = resultDescriptor.getColumnIndex(columnName); + + return idx > -1 ? getInteger(idx) : -1; + //return getInteger(resultDescriptor.getColumnIndex(columnName)); } public Integer getInteger(int column) {