Program: 11186
Project: 11186
Buggy source:
public void run(){
  int level=levels - 1;
  int tilesize=tilesizeField.getValue();
  double lzts=lztsField.getValue();
  File outDir=new File(outputDirectory.getText());
  int[] outsideValues=null;
  int[] minReplace=null;
  int[] maxReplace=null;
  Integer[] replace=null;
  Integer[] otherwise=null;
  boolean overviews=overviewsCheck.isSelected();
  if (outsideCheck.isSelected()) {
    outsideValues=new int[outputBandCount];
    for (int b=0; b < outputBandCount; b++) {
      Integer value=outsideFields[b].getValue();
      outsideValues[b]=value != null ? value : 0;
    }
  }
  if (replaceCheck.isSelected()) {
    minReplace=new int[outputBandCount];
    maxReplace=new int[outputBandCount];
    replace=new Integer[outputBandCount];
    otherwise=new Integer[outputBandCount];
    for (int b=0; b < outputBandCount; b++) {
      Integer value=minFields[b].getValue();
      minReplace[b]=value != null ? value : 0;
      value=maxFields[b].getValue();
      maxReplace[b]=value != null ? value : 0;
      replace[b]=replaceFields[b].getValue();
      otherwise[b]=otherwiseFields[b].getValue();
    }
  }
  String imageFormat=pngRadio.isSelected() ? "String_Node_Str" : "String_Node_Str";
  if (mapnikRadio.isSelected()) {
    Tiler.tileMapnik(mapFile,sector,level,tilesize,lzts,imageFormat,outDir,reporter);
    if (overviews && !reporter.isCancelled()) {
      Overviewer.createImageOverviews(outDir,imageFormat,tilesize,tilesize,outsideValues,sector,lzts,reporter);
    }
  }
 else   if (imageRadio.isSelected()) {
    boolean addAlpha=pngRadio.isSelected() && alphaCheck.isSelected();
    Tiler.tileImages(dataset,sector,level,tilesize,lzts,imageFormat,addAlpha,outsideValues,minReplace,maxReplace,replace,otherwise,outDir,reporter);
    if (overviews && !reporter.isCancelled()) {
      Overviewer.createImageOverviews(outDir,imageFormat,tilesize,tilesize,outsideValues,sector,lzts,reporter);
    }
  }
 else   if (elevationRadio.isSelected()) {
    int bufferType=byteRadio.isSelected() ? gdalconstConstants.GDT_Byte : int16Radio.isSelected() ? gdalconstConstants.GDT_Int16 : gdalconstConstants.GDT_Int32;
    int band=bandCombo.getSelectedIndex();
    Tiler.tileElevations(dataset,sector,level,tilesize,lzts,bufferType,band,outsideValues,minReplace,maxReplace,replace,otherwise,outDir,reporter);
    if (overviews && !reporter.isCancelled()) {
      Overviewer.createElevationOverviews(outDir,tilesize,tilesize,bufferType,ByteOrder.LITTLE_ENDIAN,outsideValues,sector,lzts,reporter);
    }
  }
  reporter.done();
}

Fixed version (ground truth):
public void run(){
  int level=levels - 1;
  int tilesize=tilesizeField.getValue();
  double lzts=lztsField.getValue();
  File outDir=new File(outputDirectory.getText());
  NumberArray outsideValues=null;
  NumberArray minReplace=null;
  NumberArray maxReplace=null;
  NullableNumberArray replace=null;
  NullableNumberArray otherwise=null;
  boolean overviews=overviewsCheck.isSelected();
  boolean isFloat=isFloat();
  if (outsideCheck.isSelected()) {
    outsideValues=new NumberArray(outputBandCount);
    for (int b=0; b < outputBandCount; b++) {
      if (isFloat) {
        outsideValues.setDouble(b,((JDoubleField)outsideFields[b]).getValue());
      }
 else {
        outsideValues.setLong(b,((JLongField)outsideFields[b]).getValue());
      }
    }
  }
  if (replaceCheck.isSelected()) {
    minReplace=new NumberArray(outputBandCount);
    maxReplace=new NumberArray(outputBandCount);
    replace=new NullableNumberArray(outputBandCount);
    otherwise=new NullableNumberArray(outputBandCount);
    for (int b=0; b < outputBandCount; b++) {
      if (isFloat) {
        minReplace.setDouble(b,((JDoubleField)minFields[b]).getValue());
        maxReplace.setDouble(b,((JDoubleField)maxFields[b]).getValue());
        replace.setDouble(b,((JDoubleField)replaceFields[b]).getValue());
        otherwise.setDouble(b,((JDoubleField)otherwiseFields[b]).getValue());
      }
 else {
        minReplace.setLong(b,((JLongField)minFields[b]).getValue());
        maxReplace.setLong(b,((JLongField)maxFields[b]).getValue());
        replace.setLong(b,((JLongField)replaceFields[b]).getValue());
        otherwise.setLong(b,((JLongField)otherwiseFields[b]).getValue());
      }
    }
  }
  String imageFormat=pngRadio.isSelected() ? "String_Node_Str" : "String_Node_Str";
  if (mapnikRadio.isSelected()) {
    Tiler.tileMapnik(mapFile,sector,level,tilesize,lzts,imageFormat,outDir,reporter);
    if (overviews && !reporter.isCancelled()) {
      Overviewer.createImageOverviews(outDir,imageFormat,tilesize,tilesize,outsideValues,sector,lzts,reporter);
    }
  }
 else   if (imageRadio.isSelected()) {
    boolean addAlpha=pngRadio.isSelected() && alphaCheck.isSelected();
    Tiler.tileImages(dataset,sector,level,tilesize,lzts,imageFormat,addAlpha,outsideValues,minReplace,maxReplace,replace,otherwise,outDir,reporter);
    if (overviews && !reporter.isCancelled()) {
      Overviewer.createImageOverviews(outDir,imageFormat,tilesize,tilesize,outsideValues,sector,lzts,reporter);
    }
  }
 else   if (elevationRadio.isSelected()) {
    int bufferType=byteRadio.isSelected() ? gdalconstConstants.GDT_Byte : int16Radio.isSelected() ? gdalconstConstants.GDT_Int16 : int32Radio.isSelected() ? gdalconstConstants.GDT_Int32 : gdalconstConstants.GDT_Float32;
    int band=bandCombo.getSelectedIndex();
    NumberArray minmax=new NumberArray(2);
    if (isFloat) {
      minmax.setDouble(0,Double.MAX_VALUE);
      minmax.setDouble(1,-Double.MAX_VALUE);
    }
 else {
      minmax.setLong(0,Long.MAX_VALUE);
      minmax.setLong(1,Long.MIN_VALUE);
    }
    Tiler.tileElevations(dataset,sector,level,tilesize,lzts,bufferType,band,outsideValues,minReplace,maxReplace,replace,otherwise,minmax,outDir,reporter);
    if (overviews && !reporter.isCancelled()) {
      Overviewer.createElevationOverviews(outDir,tilesize,tilesize,bufferType,ByteOrder.LITTLE_ENDIAN,outsideValues,sector,lzts,reporter);
    }
    if (isFloat) {
      reporter.getLogger().info("String_Node_Str" + minmax.getDouble(0) + "String_Node_Str"+ minmax.getDouble(1));
    }
 else {
      reporter.getLogger().info("String_Node_Str" + minmax.getLong(0) + "String_Node_Str"+ minmax.getLong(1));
    }
  }
  reporter.done();
}