small fix in histograms

small fix in histograms to avoid null
This commit is contained in:
Douglas Gillespie 2023-12-18 12:45:49 +00:00
parent 840e6c89a1
commit 4a5c6fe52e
3 changed files with 8 additions and 2 deletions

View File

@ -24,14 +24,14 @@ public class PamguardVersionInfo {
* PAMGuard can work with. * PAMGuard can work with.
*/ */
static public final String minJavaVersion = "11.0.0"; static public final String minJavaVersion = "11.0.0";
static public final String maxJavaVersion = "19.99.99"; static public final String maxJavaVersion = "21.99.99";
/** /**
* Version number, major version.minorversion.sub-release. * Version number, major version.minorversion.sub-release.
* Note: can't go higher than sub-release 'f' * Note: can't go higher than sub-release 'f'
*/ */
static public final String version = "2.02.09c"; static public final String version = "2.02.09d";
/** /**
* Release date * Release date

View File

@ -383,6 +383,9 @@ public abstract class OfflineTask<T extends PamDataUnit> {
} }
for (PamDataBlock aBlock:affectedDataBlocks) { for (PamDataBlock aBlock:affectedDataBlocks) {
if (aBlock == parentDataBlock) {
continue;
}
deleteOldData(aBlock, taskGroupParams); deleteOldData(aBlock, taskGroupParams);
} }
} }

View File

@ -407,6 +407,9 @@ public class HistogramDisplay extends Object implements Observer {
public void updateWindow() { public void updateWindow() {
int nRows = rowLabels.length; int nRows = rowLabels.length;
int iRow; int iRow;
if (numbers == null || numbers.length == 0) {
return;
}
// check all the controls are there and lay them out // check all the controls are there and lay them out
if (numbers == null || numbers.length != pamHistograms.size() || if (numbers == null || numbers.length != pamHistograms.size() ||
numbers[0].length != rowLabels.length || selectedStats != oldStatsSelection) { numbers[0].length != rowLabels.length || selectedStats != oldStatsSelection) {