Mercurial > dive4elements > river
diff flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java @ 3904:2d2ca7bf70a7
Prevent ArrayIndexOutOfBounds-Exception.
flys-artifacts/trunk@5569 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Felix Wolfsteller <felix.wolfsteller@intevation.de> |
---|---|
date | Sat, 22 Sep 2012 09:57:27 +0000 |
parents | 04309ca24614 |
children | 3dc26ec2558d |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java Sat Sep 22 09:55:01 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/CrossSectionGenerator.java Sat Sep 22 09:57:27 2012 +0000 @@ -338,7 +338,7 @@ series.setLabel(series.getLabel() + ", " + labelAdd); } } - if (ThemeUtil.parseShowLevel(theme) && lines.points.length >0 + if (ThemeUtil.parseShowLevel(theme) && lines.points.length > 1 && lines.points[1].length > 0) { NumberFormat nf = Formatter.getMeterFormat(this.context); String labelAdd = "W=" + nf.format(lines.points[1][0]) + "NN+m";