# HG changeset patch # User Felix Wolfsteller # Date 1315895410 0 # Node ID f1c9bfb07ba721908d7b6790ed998d97fca31cd3 # Parent 865ee1e19c62d8ab25cbf6cce5557ca3e07a145b Fix crash when StickyAxisAnnotation should be drawn without proper axis information. User-directed issues remain ( flys/issue303 ). flys-artifacts/trunk@2712 c6561f87-3c4e-4783-a992-168aeb5c3f6f diff -r 865ee1e19c62 -r f1c9bfb07ba7 flys-artifacts/ChangeLog --- a/flys-artifacts/ChangeLog Tue Sep 13 05:25:09 2011 +0000 +++ b/flys-artifacts/ChangeLog Tue Sep 13 06:30:10 2011 +0000 @@ -1,3 +1,13 @@ +2011-09-13 Felix Wolfsteller + + Fix crash when drawing StickyAxisAnnotation when no range was given. + User-directed issues remain ( flys/issue303 ). + + * src/main/java/de/intevation/flys/jfree/StickyAxisAnnotation.java + (draw): + Guard access to domainAxis, rangeAxis and the corresponding ranges. + Warn and exit if any was null. + 2011-09-13 Ingo Weinzierl flys/issue290 (Karte: Eingabe von Differenzen zw. WSP und Gelände findet @@ -30,6 +40,7 @@ calculation has been added to the scheduler AND if there are digitized geometries existing. +>>>>>>> .r2711 2011-09-12 Felix Wolfsteller Copied and slightly modified implementation of guessWaterIncreasing from diff -r 865ee1e19c62 -r f1c9bfb07ba7 flys-artifacts/src/main/java/de/intevation/flys/jfree/StickyAxisAnnotation.java --- a/flys-artifacts/src/main/java/de/intevation/flys/jfree/StickyAxisAnnotation.java Tue Sep 13 05:25:09 2011 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/jfree/StickyAxisAnnotation.java Tue Sep 13 06:30:10 2011 +0000 @@ -231,6 +231,14 @@ if (info == null) return; + if (domainAxis == null || rangeAxis == null + || domainAxis.getRange() == null + || rangeAxis.getRange() == null + ) { + logger.error("Annotation cannot be drawn (missing axis)."); + return; + } + // Calculate the bounding box. ChartRenderingInfo chartInfo = info.getOwner();