nus-yam/ex-repair huggingface dataset:
Program: 64959
Project: 64959
Buggy source:
public PrimitiveDiskSortedStack(int bufferSize,boolean forceDistinct,Comparator comparator){
  super(bufferSize,forceDistinct,comparator);
}

Fixed version (ground truth):
public PrimitiveDiskSortedStack(int bufferSize,boolean forceDistinct,Comparator comparator){
  super(bufferSize,forceDistinct,comparator,null);
}
Program: 64960
Project: 64960
Buggy source:
private static Date getDate(int year,int month,int day,int hours,int minutes,int seconds){
  Date newDate=new Date();
  Calendar calendar=getCalendar(newDate);
  calendar.set(year,month,day,hours,minutes,seconds);
  return calendar.getTime();
}

Fixed version (ground truth):
private static Date getDate(int year,int month,int day,int hours,int minutes,int seconds){
  Date newDate=new Date();
  Calendar calendar=getCalendar(newDate);
  calendar.set(year,month,day,hours,minutes,seconds);
  calendar.set(Calendar.MILLISECOND,0);
  return calendar.getTime();
}
Program: 64961
Project: 64961
Buggy source:
/** 
 * Find a connection available for new statements in the pool, or create a new one if none available 
 */
private CacheConnection getAvailableConnection() throws DataException {
  Iterator it=this.getOdaConnections(true).iterator();
  while (it.hasNext()) {
    CacheConnection c=(CacheConnection)(it.next());
    if (c.odaConn.isOpen() && c.currentStatements < c.maxStatements)     return c;
  }
  return newConnection();
}

Fixed version (ground truth):
/** 
 * Find a connection available for new statements in the pool, or create a new one if none available 
 */
public CacheConnection getAvailableConnection() throws DataException {
  Iterator it=this.getOdaConnections(true).iterator();
  while (it.hasNext()) {
    CacheConnection c=(CacheConnection)(it.next());
    if (c.odaConn.isOpen() && c.currentStatements < c.maxStatements)     return c;
  }
  return newConnection();
}
Program: 64962
Project: 64962
Buggy source:
public void close(){
  releaseDataSource();
}

Fixed version (ground truth):
public void close() throws DataException {
  if (odaConn != null) {
    odaConn.close();
    odaConn=null;
  }
}
Program: 64963
Project: 64963
Buggy source:
public void doCancel(){
synchronized (cancellableList) {
    for (    ICancellable cancellable : cancellableList) {
      if (cancellable.doCancel())       cancellable.cancel();
    }
  }
}

Fixed version (ground truth):
public void doCancel(){
synchronized (cancellableList) {
    List<ICancellable> cancellableLists=new ArrayList<ICancellable>(cancellableList);
    for (    ICancellable cancellable : cancellableLists) {
      if (cancellable.doCancel())       cancellable.cancel();
    }
  }
}
Program: 64964
Project: 64964
Buggy source:
public void cancel() throws OdaException, UnsupportedOperationException {
  throw new UnsupportedOperationException();
}

Fixed version (ground truth):
public void cancel() throws OdaException, UnsupportedOperationException {
  try {
    if (this.callStat != null)     this.callStat.cancel();
  }
 catch (  Exception e) {
  }
  try {
    if (this.conn != null) {
      this.conn.close();
    }
  }
 catch (  Exception e) {
  }
  try {
    IConnectionPoolManager manager=ConnectionPoolFactory.getInstance();
    if (manager != null)     manager.closeConnection(this.conn);
  }
 catch (  Exception e) {
  }
}
Program: 64965
Project: 64965
Buggy source:
public void cancel() throws OdaException {
  try {
    if (this.preStat != null) {
      System.out.println("String_Node_Str");
      this.preStat.cancel();
    }
  }
 catch (  SQLException e) {
    throw new OdaException(e);
  }
}

Fixed version (ground truth):
public void cancel() throws OdaException {
  try {
    if (this.preStat != null) {
      this.preStat.cancel();
    }
  }
 catch (  Exception e) {
  }
  try {
    if (this.conn != null) {
      this.conn.close();
    }
  }
 catch (  Exception e) {
  }
  try {
    IConnectionPoolManager manager=ConnectionPoolFactory.getInstance();
    if (manager != null)     manager.closeConnection(this.conn);
  }
 catch (  Exception e) {
  }
}
Program: 64966
Project: 64966
Buggy source:
public void stop(BundleContext context) throws Exception {
  plugin=null;
  super.stop(context);
}

Fixed version (ground truth):
public void stop(BundleContext context) throws Exception {
  plugin=null;
  ClassLoaderProvider.releaseInstance();
  super.stop(context);
}
Program: 64967
Project: 64967
Buggy source:
private URLClassLoader getPojoDataSetClassLoader() throws OdaException {
  URLParser up=new URLParser(appContext);
  URL[] urls=up.parse(pojoDataSetClassPath);
  logger.log(Level.INFO,"String_Node_Str" + Arrays.toString(urls) + "String_Node_Str");
  return new URLClassLoader(urls,Activator.class.getClassLoader());
}

Fixed version (ground truth):
private URLClassLoader getPojoDataSetClassLoader() throws OdaException {
  URLParser up=new URLParser(appContext);
  URL[] urls=up.parse(pojoDataSetClassPath);
  logger.log(Level.INFO,"String_Node_Str" + Arrays.toString(urls) + "String_Node_Str");
  URLClassLoader loader=ClassLoaderProvider.getInstance().getClassLoader(urls);
  return loader;
}
Program: 64968
Project: 64968
Buggy source:
public void close() throws OdaException {
  currentRowId=0;
  if (pojoDataSet != null) {
    pojoDataSet.close();
  }
  if (pojoClassLoader != null) {
    pojoClassLoader.close();
  }
}

Fixed version (ground truth):
public void close() throws OdaException {
  currentRowId=0;
  if (pojoDataSet != null) {
    pojoDataSet.close();
  }
}
Program: 64969
Project: 64969
Buggy source:
private String enableURI(String location){
  String result=location.replace("String_Node_Str","String_Node_Str");
  if (File.separatorChar != '/') {
    result=result.replace(File.separatorChar,'/');
  }
  if (!result.endsWith("String_Node_Str") && !result.endsWith("String_Node_Str")) {
    if (result.charAt(result.length() - 1) != '/') {
      result+="String_Node_Str";
    }
  }
  return result;
}

Fixed version (ground truth):
/** 
 * @param location
 * @return
 */
private String enableURI(String location){
  String result=location;
  try {
    if (File.separatorChar != '/')     location=location.replace(File.separatorChar,'/');
    if (location.startsWith("String_Node_Str")) {
      result=new File(location).toURI().toASCIIString().replace(new File("String_Node_Str").toURI().toASCIIString(),"String_Node_Str");
    }
 else     result=new File(location).toURI().toASCIIString().replace(new File("String_Node_Str").toURI().toASCIIString(),"String_Node_Str");
  }
 catch (  Exception e) {
    return location;
  }
  return result;
}
Program: 64971
Project: 64971
Buggy source:
public static IQueryDefinition getOptimizedIVQuery(IBaseQueryDefinition oldq,IQueryDefinition newq,String queryResultID) throws DataException {
  if (oldq == null || newq == null)   return null;
  if (!QueryCompUtil.isEqualBindings(oldq.getBindings(),newq.getBindings()))   return null;
  if (!QueryCompUtil.isEqualGroups(oldq.getGroups(),newq.getGroups(),true))   return null;
  if (!QueryCompUtil.isEqualSorts(oldq.getSorts(),newq.getSorts()))   return null;
  List<IFilterDefinition> filters=getEffectiveFilters(oldq.getFilters(),newq.getFilters());
  if (filters == null)   return null;
  NoRecalculateIVQuery query=new NoRecalculateIVQuery(newq,oldq,new LinkedList<ISortDefinition>(),filters,new LinkedList(),queryResultID);
  return query;
}

Fixed version (ground truth):
public static IQueryDefinition getOptimizedIVQuery(IBaseQueryDefinition oldq,IQueryDefinition newq,String queryResultID) throws DataException {
  if (oldq == null || newq == null)   return null;
  if (!QueryCompUtil.isEqualBindings(oldq.getBindings(),newq.getBindings()))   return null;
  if (!QueryCompUtil.isEqualGroups(oldq.getGroups(),newq.getGroups(),true))   return null;
  if (!QueryCompUtil.isEqualSorts(oldq.getSorts(),newq.getSorts()))   return null;
  List<IFilterDefinition> filters=getEffectiveFilters(oldq.getFilters(),newq.getFilters());
  if (filters == null)   return null;
  NoRecalculateIVQuery query=new NoRecalculateIVQuery(newq,oldq,new LinkedList<ISortDefinition>(),filters,newq.getGroups(),queryResultID);
  return query;
}
Program: 64973
Project: 64973
Buggy source:
/** 
 * @return
 * @throws IOException
 */
private long getOffset() throws IOException {
  return randomAccessFile.getFilePointer();
}

Fixed version (ground truth):
/** 
 * @return
 * @throws IOException
 */
private long getOffset() throws IOException {
  return getRandomAccessFile().getFilePointer();
}
Program: 64974
Project: 64974
Buggy source:
/** 
 * @throws IOException
 */
public BaseDiskArray() throws IOException {
  this.currentCacheStartIndex=0;
  this.size=0;
  this.buffer=new Object[bufferSize];
  this.segmentOffsets=new ArrayList<Long>();
  this.segmentOffsets.add(Long.valueOf(0L));
  createRandomAccessFile();
  DataEngineThreadLocal.getInstance().getCloseListener().add(this);
}

Fixed version (ground truth):
/** 
 * @throws IOException
 */
public BaseDiskArray() throws IOException {
  this.currentCacheStartIndex=0;
  this.size=0;
  this.buffer=new Object[bufferSize];
  this.segmentOffsets=new ArrayList<Long>();
  this.segmentOffsets.add(Long.valueOf(0L));
  DataEngineThreadLocal.getInstance().getCloseListener().add(this);
}
Program: 64975
Project: 64975
Buggy source:
/** 
 * Reads up to <code>readSize</code> objects from disk.
 * @param dis
 * @param list
 * @return
 * @throws IOException
 */
private void readObjects(long offset,int readSize) throws IOException {
  this.randomAccessFile.seek(offset);
  for (int i=0; i < readSize; i++) {
    this.buffer[i]=readObject();
  }
}

Fixed version (ground truth):
/** 
 * Reads up to <code>readSize</code> objects from disk.
 * @param dis
 * @param list
 * @return
 * @throws IOException
 */
private void readObjects(long offset,int readSize) throws IOException {
  getRandomAccessFile().seek(offset);
  for (int i=0; i < readSize; i++) {
    this.buffer[i]=readObject();
  }
}
Program: 64976
Project: 64976
Buggy source:
protected void writeObject(Object object) throws IOException {
  if (object == null) {
    randomAccessFile.writeShort(NULL_VALUE);
    return;
  }
  randomAccessFile.writeShort(NORMAL_VALUE);
  if (fieldWriter == null) {
    fieldWriter=IOUtil.getRandomWriter(DataType.getDataType(object.getClass()));
    fieldReader=IOUtil.getRandomReader(DataType.getDataType(object.getClass()));
  }
  fieldWriter.write(randomAccessFile,object);
}

Fixed version (ground truth):
protected void writeObject(Object object) throws IOException {
  if (object == null) {
    getRandomAccessFile().writeShort(NULL_VALUE);
    return;
  }
  getRandomAccessFile().writeShort(NORMAL_VALUE);
  if (fieldWriter == null) {
    fieldWriter=IOUtil.getRandomWriter(DataType.getDataType(object.getClass()));
    fieldReader=IOUtil.getRandomReader(DataType.getDataType(object.getClass()));
  }
  fieldWriter.write(getRandomAccessFile(),object);
}
Program: 64977
Project: 64977
Buggy source:
protected Object readObject() throws IOException {
  short fieldCount=randomAccessFile.readShort();
  if (fieldCount == NULL_VALUE) {
    return null;
  }
  return fieldReader.read(randomAccessFile);
}

Fixed version (ground truth):
protected Object readObject() throws IOException {
  short fieldCount=getRandomAccessFile().readShort();
  if (fieldCount == NULL_VALUE) {
    return null;
  }
  return fieldReader.read(getRandomAccessFile());
}
Program: 64978
Project: 64978
Buggy source:
protected void writeObject(Object object) throws IOException {
  if (object == null) {
    randomAccessFile.writeShort(NULL_VALUE);
    return;
  }
  IStructure cachedObject=(IStructure)object;
  Object[] objects=cachedObject.getFieldValues();
  randomAccessFile.writeShort((short)objects.length);
  if (fieldWriters == null || fieldWriters.length < objects.length) {
    createReadersAndWriters(objects.length);
  }
  for (int i=0; i < objects.length; i++) {
    if (i >= fieldWriters.length) {
      fieldWriters[fieldWriters.length - 1].write(randomAccessFile,objects[i]);
    }
 else {
      fieldWriters[i].write(randomAccessFile,objects[i]);
    }
  }
}

Fixed version (ground truth):
protected void writeObject(Object object) throws IOException {
  if (object == null) {
    getRandomAccessFile().writeShort(NULL_VALUE);
    return;
  }
  IStructure cachedObject=(IStructure)object;
  Object[] objects=cachedObject.getFieldValues();
  getRandomAccessFile().writeShort((short)objects.length);
  if (fieldWriters == null || fieldWriters.length < objects.length) {
    createReadersAndWriters(objects.length);
  }
  for (int i=0; i < objects.length; i++) {
    if (i >= fieldWriters.length) {
      fieldWriters[fieldWriters.length - 1].write(getRandomAccessFile(),objects[i]);
    }
 else {
      fieldWriters[i].write(getRandomAccessFile(),objects[i]);
    }
  }
}
Program: 64979
Project: 64979
Buggy source:
protected Object readObject() throws IOException {
  short fieldCount=randomAccessFile.readShort();
  if (fieldCount == NULL_VALUE) {
    return null;
  }
  Object[] objects=new Object[fieldCount];
  for (int i=0; i < objects.length; i++) {
    if (i < fieldReaders.length && fieldReaders[i].getDataType() != fieldWriters[i].getDataType())     fieldReaders[i].setDataType(fieldWriters[i].getDataType());
    if (i >= fieldReaders.length) {
      objects[i]=fieldReaders[fieldReaders.length - 1].read(randomAccessFile);
    }
 else {
      objects[i]=fieldReaders[i].read(randomAccessFile);
    }
  }
  return creator.createInstance(objects);
}

Fixed version (ground truth):
protected Object readObject() throws IOException {
  short fieldCount=getRandomAccessFile().readShort();
  if (fieldCount == NULL_VALUE) {
    return null;
  }
  Object[] objects=new Object[fieldCount];
  for (int i=0; i < objects.length; i++) {
    if (i < fieldReaders.length && fieldReaders[i].getDataType() != fieldWriters[i].getDataType())     fieldReaders[i].setDataType(fieldWriters[i].getDataType());
    if (i >= fieldReaders.length) {
      objects[i]=fieldReaders[fieldReaders.length - 1].read(getRandomAccessFile());
    }
 else {
      objects[i]=fieldReaders[i].read(getRandomAccessFile());
    }
  }
  return creator.createInstance(objects);
}
Program: 64980
Project: 64980
Buggy source:
public IParameterDefn[] getParameterDefn(){
  IParameterDefn paramDefn[]=new IParameterDefn[]{new ParameterDefn(Constants.EXPRESSION_NAME,Constants.EXPRESSION_DISPLAY_NAME,false,true,SupportedDataTypes.ANY,Messages.getString("String_Node_Str")),new ParameterDefn(Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str"),true,false,SupportedDataTypes.CALCULATABLE,Messages.getString("String_Node_Str")),new ParameterDefn(Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str"),true,false,SupportedDataTypes.CALCULATABLE,Messages.getString("String_Node_Str")),new ParameterDefn(Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str"),true,false,SupportedDataTypes.CALCULATABLE,Messages.getString("String_Node_Str"))};
  return paramDefn;
}

Fixed version (ground truth):
public IParameterDefn[] getParameterDefn(){
  IParameterDefn paramDefn[]=new IParameterDefn[]{new ParameterDefn(Constants.EXPRESSION_NAME,Constants.EXPRESSION_DISPLAY_NAME,false,true,SupportedDataTypes.ANY,Messages.getString("String_Node_Str")),new ParameterDefn(Constants.SEPARATOR_NAME,Constants.SEPARATOR_DISPLAY_NAME,true,false,SupportedDataTypes.CALCULATABLE,Messages.getString("String_Node_Str")),new ParameterDefn(Constants.MAXLENGTH_NAME,Constants.MAXLENGTH__DISPLAY_NAME,true,false,SupportedDataTypes.CALCULATABLE,Messages.getString("String_Node_Str")),new ParameterDefn(Constants.SHOWALLVALUES_NAME,Constants.SHOWALLVALUES_DISPLAY_NAME,true,false,SupportedDataTypes.CALCULATABLE,Messages.getString("String_Node_Str"))};
  return paramDefn;
}
Program: 64981
Project: 64981
Buggy source:
/** 
 */
public void cancel(){
  try {
    this.statement.cancel();
  }
 catch (  DataException e) {
    this.exception=e;
  }
}

Fixed version (ground truth):
/** 
 */
public void cancel(){
  try {
    this.statement.cancel();
  }
 catch (  Exception e) {
    try {
      this.statement.close();
    }
 catch (    Exception e1) {
      this.exception=new DataException(e.getLocalizedMessage(),e);
    }
  }
}
Program: 64983
Project: 64983
Buggy source:
public int getSubQueryStartingIndex() throws DataException {
  if (!subQueryOnGroup)   return this.parentIterator.getCurrentResultIndex();
  int groupIndex=this.parentIterator.getCurrentGroupIndex(groupLevel);
  int[] groupStartingEndingIndex=this.parentIterator.getGroupStartAndEndIndex(groupLevel);
  return (this.parentExecutor instanceof ISubQueryExecutor) ? ((ISubQueryExecutor)this.parentExecutor).getSubQueryStartingIndex() + groupStartingEndingIndex[groupIndex * 2] : groupStartingEndingIndex[groupIndex * 2];
}

Fixed version (ground truth):
public int getSubQueryStartingIndex() throws DataException {
  if (!subQueryOnGroup)   return this.parentIterator.getCurrentResultIndex();
  if (parentIterator instanceof EmptyResultIterator)   return 0;
  int groupIndex=this.parentIterator.getCurrentGroupIndex(groupLevel);
  int[] groupStartingEndingIndex=this.parentIterator.getGroupStartAndEndIndex(groupLevel);
  return (this.parentExecutor instanceof ISubQueryExecutor) ? ((ISubQueryExecutor)this.parentExecutor).getSubQueryStartingIndex() + groupStartingEndingIndex[groupIndex * 2] : groupStartingEndingIndex[groupIndex * 2];
}
Program: 64984
Project: 64984
Buggy source:
/** 
 * Splits text for fixed layout reports.
 */
private void splitText(){
  Integer taskType=(Integer)engine.getOption(EngineTask.TASK_TYPE);
  if (taskType.intValue() == IEngineTask.TASK_RENDER && context.isFixedLayout()) {
    SizeBasedContent sizeBasedContent=context.getPageHintManager().getSizeBasedContentMapping().get(content.getInstanceID().toUniqueString());
    if (sizeBasedContent == null || sizeBasedContent.dimension == -1) {
      return;
    }
    HtmlRegionArea container=new HtmlRegionArea();
    container.setWidth(sizeBasedContent.width);
    IReportContent report=content.getReportContent();
    IContainerContent containerContent=report.createContainerContent();
    containerContent.getChildren().add(content);
    LayoutContext pdfLayoutContext=new LayoutContext();
    pdfLayoutContext.setFormat("String_Node_Str");
    pdfLayoutContext.setFixedLayout(true);
    pdfLayoutContext.setInHtmlRender(true);
    pdfLayoutContext.setLocale(engine.locale);
    pdfLayoutContext.setHtmlLayoutContext(context);
    pdfLayoutContext.setMaxBP(Integer.MAX_VALUE);
    pdfLayoutContext.setReport(report);
    RegionLayoutEngine rle=new RegionLayoutEngine(container,pdfLayoutContext);
    try {
      rle.layout(containerContent);
    }
 catch (    BirtException e) {
      logger.log(Level.WARNING,e.getMessage(),e);
    }
  }
}

Fixed version (ground truth):
/** 
 * Splits text for fixed layout reports.
 */
private void splitText(){
  Integer taskType=(Integer)engine.getOption(EngineTask.TASK_TYPE);
  if (taskType.intValue() == IEngineTask.TASK_RENDER && context.isFixedLayout()) {
    SizeBasedContent sizeBasedContent=context.getPageHintManager().getSizeBasedContentMapping().get(content.getInstanceID().toUniqueString());
    if (sizeBasedContent == null || sizeBasedContent.dimension == -1) {
      return;
    }
    HtmlRegionArea container=new HtmlRegionArea();
    container.setWidth(sizeBasedContent.width);
    IReportContent report=content.getReportContent();
    IContainerContent containerContent=report.createContainerContent();
    containerContent.getChildren().add(content);
    LayoutContext pdfLayoutContext=new LayoutContext();
    pdfLayoutContext.setFormat("String_Node_Str");
    pdfLayoutContext.setFixedLayout(true);
    pdfLayoutContext.setInHtmlRender(true);
    pdfLayoutContext.setLocale(engine.locale);
    pdfLayoutContext.setHtmlLayoutContext(context);
    pdfLayoutContext.setMaxBP(Integer.MAX_VALUE);
    pdfLayoutContext.setMaxHeight(Integer.MAX_VALUE);
    pdfLayoutContext.setReport(report);
    RegionLayoutEngine rle=new RegionLayoutEngine(container,pdfLayoutContext);
    try {
      rle.layout(containerContent);
    }
 catch (    BirtException e) {
      logger.log(Level.WARNING,e.getMessage(),e);
    }
  }
}
Program: 64986
Project: 64986
Buggy source:
/** 
 * Convert an object to an locale neutral String value. For Date values we will convert to ISO8601 format.
 * @param source
 * @return
 * @throws BirtException
 */
public static String toLocaleNeutralString(Object source) throws BirtException {
  if (source == null)   return null;
  if (source instanceof Time) {
    return ((Time)source).toString();
  }
 else   if (source instanceof java.sql.Date) {
    return ((java.sql.Date)source).toString();
  }
 else   if (source instanceof Timestamp) {
    return ((java.sql.Timestamp)source).toString();
  }
 else   if (source instanceof Date) {
    return DateFormatISO8601.format((Date)source);
  }
 else   if (source instanceof Number) {
    return ((Number)source).toString();
  }
 else {
    return toLimitedSizeString(source);
  }
}

Fixed version (ground truth):
/** 
 * Convert an object to an locale neutral String value. For Date values we will convert to ISO8601 format. This will always output default(current) time zone.
 * @param source
 * @return
 * @throws BirtException
 */
public static String toLocaleNeutralString(Object source) throws BirtException {
  if (source == null)   return null;
  if (source instanceof Time) {
    return ((Time)source).toString();
  }
 else   if (source instanceof java.sql.Date) {
    return ((java.sql.Date)source).toString();
  }
 else   if (source instanceof Timestamp) {
    return ((java.sql.Timestamp)source).toString();
  }
 else   if (source instanceof Date) {
    return DateFormatISO8601.format((Date)source);
  }
 else   if (source instanceof Number) {
    return ((Number)source).toString();
  }
 else {
    return toLimitedSizeString(source);
  }
}
Program: 64987
Project: 64987
Buggy source:
/** 
 * Parse a date/time string.
 * @param source
 * @return
 * @throws ParseException
 */
public static String format(Date date) throws BirtException {
  String result=null;
  if (date == null) {
    return null;
  }
  Object simpleDateFormatter=DateFormatFactory.getPatternInstance(PatternKey.getPatterKey("String_Node_Str"));
  if (simpleDateFormatter != null) {
    try {
      result=((SimpleDateFormat)simpleDateFormatter).format(date);
      return result;
    }
 catch (    Exception e1) {
    }
  }
  throw new CoreException(ResourceConstants.CONVERT_FAILS,new Object[]{date.toString(),"String_Node_Str"});
}

Fixed version (ground truth):
/** 
 * Parse a date/time string.
 * @param source
 * @return
 * @throws ParseException
 */
public static String format(Date date) throws BirtException {
  return format(date,TimeZone.getDefault());
}
Program: 64992
Project: 64992
Buggy source:
/** 
 * This test writes the design file and compare it with golden file.
 * @throws Exception
 */
public void testWriter() throws Exception {
  openDesign(fileName);
  GridHandle grid=(GridHandle)designHandle.findElement("String_Node_Str");
  grid.setCaption("String_Node_Str");
  grid.setCaptionKey("String_Node_Str");
  grid.setSummary("String_Node_Str");
  grid.setRole("String_Node_Str");
  grid.setLanguage("String_Node_Str");
  grid.setOrder(1);
  SlotHandle rows=grid.getRows();
  RowHandle row=(RowHandle)rows.get(0);
  SlotHandle cells=row.getCells();
  CellHandle cell=(CellHandle)cells.get(1);
  cell.setDiagonalStyle(DesignChoiceConstants.LINE_STYLE_INSET);
  cell.setAntidiagonalStyle(DesignChoiceConstants.LINE_STYLE_OUTSET);
  cell.setDiagonalNumber(20);
  cell.setAntidiagonalNumber(30);
  cell.setProperty(ICellModel.DIAGONAL_THICKNESS_PROP,"String_Node_Str");
  cell.setProperty(ICellModel.ANTIDIAGONAL_THICKNESS_PROP,"String_Node_Str");
  cell.setRole("String_Node_Str");
  cell.setLanguage("String_Node_Str");
  cell.setAltText("String_Node_Str");
  ColorHandle colorHandle=cell.getDiagonalColor();
  colorHandle.setStringValue(ColorPropertyType.YELLOW);
  colorHandle=cell.getAntidiagonalColor();
  colorHandle.setStringValue(ColorPropertyType.OLIVE);
  cell.setScope(DesignChoiceConstants.SCOPE_TYPE_COL);
  cell.setBookmark("String_Node_Str");
  cell.setHeaders("String_Node_Str");
  save();
  assertTrue(compareFile(goldenFileName));
}

Fixed version (ground truth):
/** 
 * This test writes the design file and compare it with golden file.
 * @throws Exception
 */
public void testWriter() throws Exception {
  openDesign(fileName);
  GridHandle grid=(GridHandle)designHandle.findElement("String_Node_Str");
  grid.setCaption("String_Node_Str");
  grid.setCaptionKey("String_Node_Str");
  grid.setSummary("String_Node_Str");
  grid.setTagType("String_Node_Str");
  grid.setLanguage("String_Node_Str");
  grid.setOrder(1);
  SlotHandle rows=grid.getRows();
  RowHandle row=(RowHandle)rows.get(0);
  SlotHandle cells=row.getCells();
  CellHandle cell=(CellHandle)cells.get(1);
  cell.setDiagonalStyle(DesignChoiceConstants.LINE_STYLE_INSET);
  cell.setAntidiagonalStyle(DesignChoiceConstants.LINE_STYLE_OUTSET);
  cell.setDiagonalNumber(20);
  cell.setAntidiagonalNumber(30);
  cell.setProperty(ICellModel.DIAGONAL_THICKNESS_PROP,"String_Node_Str");
  cell.setProperty(ICellModel.ANTIDIAGONAL_THICKNESS_PROP,"String_Node_Str");
  cell.setTagType("String_Node_Str");
  cell.setLanguage("String_Node_Str");
  cell.setAltText("String_Node_Str");
  ColorHandle colorHandle=cell.getDiagonalColor();
  colorHandle.setStringValue(ColorPropertyType.YELLOW);
  colorHandle=cell.getAntidiagonalColor();
  colorHandle.setStringValue(ColorPropertyType.OLIVE);
  cell.setScope(DesignChoiceConstants.SCOPE_TYPE_COL);
  cell.setBookmark("String_Node_Str");
  cell.setHeaders("String_Node_Str");
  save();
  assertTrue(compareFile(goldenFileName));
}
Program: 64998
Project: 64998
Buggy source:
/** 
 * Test writer.
 * @throws Exception if any exception
 */
public void testWriter() throws Exception {
  ListHandle listHandle=(ListHandle)designHandle.findElement("String_Node_Str");
  assertNotNull(listHandle);
  listHandle.setOnPrepare("String_Node_Str");
  listHandle.setOnCreate("String_Node_Str");
  listHandle.setOnRender(null);
  listHandle.setPageBreakInterval(100);
  listHandle.setOnPageBreak("String_Node_Str");
  listHandle.setRole("String_Node_Str");
  listHandle.setLanguage("String_Node_Str");
  listHandle.setAltText("String_Node_Str");
  GroupHandle groupHandle=(GroupHandle)listHandle.getGroups().get(0);
  groupHandle.setGroupStart("String_Node_Str");
  groupHandle.setTocExpression("String_Node_Str");
  groupHandle.setSortType("String_Node_Str");
  groupHandle.setOnPageBreak("String_Node_Str");
  groupHandle.setOnCreate("String_Node_Str");
  groupHandle.setOnRender("String_Node_Str");
  groupHandle.setShowDetailFilter(true);
  assertEquals("String_Node_Str",groupHandle.getBookmark());
  groupHandle.setBookmark("String_Node_Str");
  save();
  assertTrue(compareFile(goldenFileName));
}

Fixed version (ground truth):
/** 
 * Test writer.
 * @throws Exception if any exception
 */
public void testWriter() throws Exception {
  ListHandle listHandle=(ListHandle)designHandle.findElement("String_Node_Str");
  assertNotNull(listHandle);
  listHandle.setOnPrepare("String_Node_Str");
  listHandle.setOnCreate("String_Node_Str");
  listHandle.setOnRender(null);
  listHandle.setPageBreakInterval(100);
  listHandle.setOnPageBreak("String_Node_Str");
  listHandle.setTagType("String_Node_Str");
  listHandle.setLanguage("String_Node_Str");
  listHandle.setAltText("String_Node_Str");
  GroupHandle groupHandle=(GroupHandle)listHandle.getGroups().get(0);
  groupHandle.setGroupStart("String_Node_Str");
  groupHandle.setTocExpression("String_Node_Str");
  groupHandle.setSortType("String_Node_Str");
  groupHandle.setOnPageBreak("String_Node_Str");
  groupHandle.setOnCreate("String_Node_Str");
  groupHandle.setOnRender("String_Node_Str");
  groupHandle.setShowDetailFilter(true);
  assertEquals("String_Node_Str",groupHandle.getBookmark());
  groupHandle.setBookmark("String_Node_Str");
  save();
  assertTrue(compareFile(goldenFileName));
}
Program: 65001
Project: 65001
Buggy source:
/** 
 * Test all properties.
 * @throws Exception if opening design file failed.
 */
public void testParser() throws Exception {
  openDesign(fileName);
  TextDataHandle dataHandle=(TextDataHandle)designHandle.findElement("String_Node_Str");
  assertNotNull(dataHandle.getElement());
  assertEquals("String_Node_Str",dataHandle.getValueExpr());
  assertEquals(DesignChoiceConstants.TEXT_DATA_CONTENT_TYPE_AUTO,dataHandle.getContentType());
  assertTrue(dataHandle.hasExpression());
  assertEquals("String_Node_Str",dataHandle.getRole());
  assertEquals("String_Node_Str",dataHandle.getLanguage());
  assertEquals("String_Node_Str",dataHandle.getAltText());
  assertEquals(1,dataHandle.getOrder());
  TextDataHandle data2Handle=(TextDataHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",data2Handle.getRole());
}

Fixed version (ground truth):
/** 
 * Test all properties.
 * @throws Exception if opening design file failed.
 */
public void testParser() throws Exception {
  openDesign(fileName);
  TextDataHandle dataHandle=(TextDataHandle)designHandle.findElement("String_Node_Str");
  assertNotNull(dataHandle.getElement());
  assertEquals("String_Node_Str",dataHandle.getValueExpr());
  assertEquals(DesignChoiceConstants.TEXT_DATA_CONTENT_TYPE_AUTO,dataHandle.getContentType());
  assertTrue(dataHandle.hasExpression());
  assertEquals("String_Node_Str",dataHandle.getTagType());
  assertEquals("String_Node_Str",dataHandle.getLanguage());
  assertEquals("String_Node_Str",dataHandle.getAltText());
  assertEquals(1,dataHandle.getOrder());
  TextDataHandle data2Handle=(TextDataHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",data2Handle.getTagType());
}
Program: 65002
Project: 65002
Buggy source:
/** 
 * This test sets properties, writes the design file and compares it with golden file.
 * @throws Exception if opening or saving design file failed.
 */
public void testWriter() throws Exception {
  openDesign(fileName);
  TextDataHandle dataHandle=(TextDataHandle)designHandle.findElement("String_Node_Str");
  assertNotNull(dataHandle.getElement());
  dataHandle.setValueExpr("String_Node_Str");
  dataHandle.setContentType(DesignChoiceConstants.TEXT_DATA_CONTENT_TYPE_RTF);
  dataHandle.setHasExpression(false);
  dataHandle.setRole("String_Node_Str");
  dataHandle.setLanguage("String_Node_Str");
  dataHandle.setAltText("String_Node_Str");
  dataHandle.setOrder(1);
  save();
  assertTrue(compareFile(goldenFileName));
}

Fixed version (ground truth):
/** 
 * This test sets properties, writes the design file and compares it with golden file.
 * @throws Exception if opening or saving design file failed.
 */
public void testWriter() throws Exception {
  openDesign(fileName);
  TextDataHandle dataHandle=(TextDataHandle)designHandle.findElement("String_Node_Str");
  assertNotNull(dataHandle.getElement());
  dataHandle.setValueExpr("String_Node_Str");
  dataHandle.setContentType(DesignChoiceConstants.TEXT_DATA_CONTENT_TYPE_RTF);
  dataHandle.setHasExpression(false);
  dataHandle.setTagType("String_Node_Str");
  dataHandle.setLanguage("String_Node_Str");
  dataHandle.setAltText("String_Node_Str");
  dataHandle.setOrder(1);
  save();
  assertTrue(compareFile(goldenFileName));
}
Program: 65003
Project: 65003
Buggy source:
/** 
 * Test the write for user-defined properties.
 * @throws Exception
 */
public void testWrite() throws Exception {
  openDesign("String_Node_Str");
  TextItemHandle text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  String contentType=text.getContentType();
  assertEquals(DesignChoiceConstants.TEXT_CONTENT_TYPE_HTML,contentType);
  text.setContentType(DesignChoiceConstants.TEXT_CONTENT_TYPE_HTML);
  text.setContent("String_Node_Str");
  text.setHasExpression(false);
  text.setRole("String_Node_Str");
  text.setLanguage("String_Node_Str");
  text.setAltText("String_Node_Str");
  text.setOrder(1);
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  text.setContent("String_Node_Str");
  assertEquals("String_Node_Str",text.getProperty(TextItem.CONTENT_PROP));
  assertEquals("String_Node_Str",text.getStringProperty(TextItem.CONTENT_PROP));
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  text.setContentKey("String_Node_Str");
  save();
  assertTrue(compareFile("String_Node_Str"));
}

Fixed version (ground truth):
/** 
 * Test the write for user-defined properties.
 * @throws Exception
 */
public void testWrite() throws Exception {
  openDesign("String_Node_Str");
  TextItemHandle text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  String contentType=text.getContentType();
  assertEquals(DesignChoiceConstants.TEXT_CONTENT_TYPE_HTML,contentType);
  text.setContentType(DesignChoiceConstants.TEXT_CONTENT_TYPE_HTML);
  text.setContent("String_Node_Str");
  text.setHasExpression(false);
  text.setTagType("String_Node_Str");
  text.setLanguage("String_Node_Str");
  text.setAltText("String_Node_Str");
  text.setOrder(1);
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  text.setContent("String_Node_Str");
  assertEquals("String_Node_Str",text.getProperty(TextItem.CONTENT_PROP));
  assertEquals("String_Node_Str",text.getStringProperty(TextItem.CONTENT_PROP));
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  text.setContentKey("String_Node_Str");
  save();
  assertTrue(compareFile("String_Node_Str"));
}
Program: 65004
Project: 65004
Buggy source:
/** 
 * Test the properties for user-defined properties.
 * @throws Exception
 */
public void testProperties() throws Exception {
  openDesign("String_Node_Str");
  TextItemHandle text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  String contentType=text.getContentType();
  assertEquals(DesignChoiceConstants.TEXT_CONTENT_TYPE_HTML,contentType);
  assertTrue(text.hasExpression());
  assertEquals("String_Node_Str",text.getContent());
  assertEquals("String_Node_Str",text.getRole());
  assertEquals("String_Node_Str",text.getLanguage());
  assertEquals("String_Node_Str",text.getAltText());
  assertEquals(1,text.getOrder());
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  assertNull(text.getContentKey());
  assertEquals(DesignChoiceConstants.TEXT_CONTENT_TYPE_AUTO,text.getContentType());
  assertEquals("String_Node_Str",text.getContent());
  assertEquals("String_Node_Str",text.getRole());
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",text.getContentKey());
  assertEquals(DesignChoiceConstants.TEXT_CONTENT_TYPE_AUTO,text.getContentType());
  assertEquals("String_Node_Str",text.getContent());
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",text.getContent());
}

Fixed version (ground truth):
/** 
 * Test the properties for user-defined properties.
 * @throws Exception
 */
public void testProperties() throws Exception {
  openDesign("String_Node_Str");
  TextItemHandle text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  String contentType=text.getContentType();
  assertEquals(DesignChoiceConstants.TEXT_CONTENT_TYPE_HTML,contentType);
  assertTrue(text.hasExpression());
  assertEquals("String_Node_Str",text.getContent());
  assertEquals("String_Node_Str",text.getTagType());
  assertEquals("String_Node_Str",text.getLanguage());
  assertEquals("String_Node_Str",text.getAltText());
  assertEquals(1,text.getOrder());
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  assertNull(text.getContentKey());
  assertEquals(DesignChoiceConstants.TEXT_CONTENT_TYPE_AUTO,text.getContentType());
  assertEquals("String_Node_Str",text.getContent());
  assertEquals("String_Node_Str",text.getTagType());
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",text.getContentKey());
  assertEquals(DesignChoiceConstants.TEXT_CONTENT_TYPE_AUTO,text.getContentType());
  assertEquals("String_Node_Str",text.getContent());
  text=(TextItemHandle)designHandle.findElement("String_Node_Str");
  assertEquals("String_Node_Str",text.getContent());
}
Program: 65005
Project: 65005
Buggy source:
protected void bindBinding(IBinding colBinding,ICubeQueryDefinition cubeQuery,CubeHandle cube) throws BirtException {
  if (colBinding == null) {
    return;
  }
  String bindingName=colBinding.getBindingName();
  String expr=registeredQueries.get(bindingName).encode();
  if (!cubeQuery.getBindings().contains(colBinding)) {
    cubeQuery.addBinding(colBinding);
  }
  String measure=exprCodec.getMeasureName(expr);
  if (measure != null) {
    if (registeredMeasures.containsKey(bindingName)) {
      return;
    }
    IMeasureDefinition mDef=null;
    MeasureHandle measureHandle=cube.getMeasure(measure);
    if (measureHandle != null && measureHandle.isCalculated()) {
      mDef=cubeQuery.createDerivedMeasure(measure,DataAdapterUtil.adaptModelDataType(measureHandle.getDataType()),modelAdapter.adaptExpression((Expression)measureHandle.getExpressionProperty(IMeasureModel.MEASURE_EXPRESSION_PROP).getValue(),ExpressionLocation.CUBE));
    }
 else {
      mDef=cubeQuery.createMeasure(measure);
    }
    registeredMeasures.put(bindingName,mDef);
    String aggFun=DataAdapterUtil.adaptModelAggregationType(cube.getMeasure(measure).getFunction());
    mDef.setAggrFunction(aggFun);
  }
 else   if (exprCodec.isDimensionExpresion()) {
    registerDimensionLevel(cubeQuery,cube,bindingName);
  }
 else   if (exprCodec.isCubeBinding(true)) {
    bindExpression(expr,cubeQuery,cube);
    return;
  }
}

Fixed version (ground truth):
protected void bindBinding(IBinding colBinding,ICubeQueryDefinition cubeQuery,CubeHandle cube) throws BirtException {
  if (colBinding == null) {
    return;
  }
  String bindingName=colBinding.getBindingName();
  String expr=registeredQueries.get(bindingName).encode();
  if (!cubeQuery.getBindings().contains(colBinding)) {
    cubeQuery.addBinding(colBinding);
  }
  String measure=exprCodec.getMeasureName(expr);
  if (measure != null) {
    if (registeredMeasures.containsKey(bindingName)) {
      return;
    }
    IMeasureDefinition mDef=null;
    MeasureHandle measureHandle=cube.getMeasure(measure);
    if (measureHandle != null && measureHandle.isCalculated()) {
      mDef=cubeQuery.createDerivedMeasure(measure,DataAdapterUtil.adaptModelDataType(measureHandle.getDataType()),modelAdapter.adaptExpression((Expression)measureHandle.getExpressionProperty(IMeasureModel.MEASURE_EXPRESSION_PROP).getValue(),ExpressionLocation.CUBE));
    }
 else {
      mDef=cubeQuery.createMeasure(measure);
    }
    registeredMeasures.put(bindingName,mDef);
    if (cube.getMeasure(measure) != null) {
      String aggFun=DataAdapterUtil.adaptModelAggregationType(cube.getMeasure(measure).getFunction());
      mDef.setAggrFunction(aggFun);
    }
  }
 else   if (exprCodec.isDimensionExpresion()) {
    registerDimensionLevel(cubeQuery,cube,bindingName);
  }
 else   if (exprCodec.isCubeBinding(true)) {
    bindExpression(expr,cubeQuery,cube);
    return;
  }
}
Program: 65006
Project: 65006
Buggy source:
@SuppressWarnings("String_Node_Str") private List<FilterConditionElementHandle> getFiltersFromXtab(CrosstabReportItemHandle crossTab){
  List<FilterConditionElementHandle> list=new ArrayList<FilterConditionElementHandle>();
  if (crossTab == null) {
    return list;
  }
  if (crossTab.getCrosstabView(ICrosstabConstants.COLUMN_AXIS_TYPE) != null) {
    DesignElementHandle elementHandle=crossTab.getCrosstabView(ICrosstabConstants.COLUMN_AXIS_TYPE).getModelHandle();
    list.addAll(getLevelOnCrosstab((ExtendedItemHandle)elementHandle));
  }
  if (crossTab.getCrosstabView(ICrosstabConstants.ROW_AXIS_TYPE) != null) {
    DesignElementHandle elementHandle=crossTab.getCrosstabView(ICrosstabConstants.ROW_AXIS_TYPE).getModelHandle();
    list.addAll(getLevelOnCrosstab((ExtendedItemHandle)elementHandle));
  }
  int measureCount=crossTab.getMeasureCount();
  for (int i=0; i < measureCount; i++) {
    MeasureViewHandle measureView=crossTab.getMeasure(i);
    Iterator<FilterConditionElementHandle> iter=measureView.filtersIterator();
    while (iter.hasNext()) {
      list.add(iter.next());
    }
  }
  return list;
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") private List<FilterConditionElementHandle> getFiltersFromXtab(CrosstabReportItemHandle crossTab){
  List<FilterConditionElementHandle> list=new ArrayList<FilterConditionElementHandle>();
  if (crossTab == null) {
    return list;
  }
  if (crossTab.getCrosstabView(ICrosstabConstants.COLUMN_AXIS_TYPE) != null) {
    DesignElementHandle elementHandle=crossTab.getCrosstabView(ICrosstabConstants.COLUMN_AXIS_TYPE).getModelHandle();
    list.addAll(getLevelOnCrosstab((ExtendedItemHandle)elementHandle));
  }
  if (crossTab.getCrosstabView(ICrosstabConstants.ROW_AXIS_TYPE) != null) {
    DesignElementHandle elementHandle=crossTab.getCrosstabView(ICrosstabConstants.ROW_AXIS_TYPE).getModelHandle();
    list.addAll(getLevelOnCrosstab((ExtendedItemHandle)elementHandle));
  }
  int measureCount=crossTab.getMeasureCount();
  for (int i=0; i < measureCount; i++) {
    MeasureViewHandle measureView=crossTab.getMeasure(i);
    if (measureView != null) {
      Iterator<FilterConditionElementHandle> iter=measureView.filtersIterator();
      while (iter.hasNext()) {
        list.add(iter.next());
      }
    }
  }
  return list;
}
Program: 65007
Project: 65007
Buggy source:
public void close() throws BirtException {
  height=currentBP + getOffsetY() + localProperties.getPaddingBottom();
  updateBackgroundImage();
  checkPageBreak();
  parent.update(this);
  finished=true;
  checkDisplayNone();
}

Fixed version (ground truth):
public void close() throws BirtException {
  height=currentBP + getOffsetY() + localProperties.getPaddingBottom();
  checkPageBreak();
  parent.update(this);
  finished=true;
  checkDisplayNone();
}
Program: 65008
Project: 65008
Buggy source:
public void close() throws BirtException {
  TableArea table=getTableArea();
  table.addRow(this);
  updateBackgroundImage();
  parent.update(this);
  finished=true;
  checkDisplayNone();
}

Fixed version (ground truth):
public void close() throws BirtException {
  TableArea table=getTableArea();
  table.addRow(this);
  updateBackgroundImage();
  updateCellBackgroundImage();
  parent.update(this);
  finished=true;
  checkDisplayNone();
}
Program: 65009
Project: 65009
Buggy source:
/** 
 * Transforms dimension value to points.
 * @param handle
 * @param dpi to convert px unit
 * @return the dimension value with measure of points
 * @since 2.3
 */
public static double convertToPoints(org.eclipse.birt.report.model.api.DimensionHandle handle,int dpi){
  double retValue=0.0;
  if (handle.getMeasure() > 0 && handle.getUnits().trim().length() > 0) {
    if (handle.getUnits() == DesignChoiceConstants.UNITS_PT) {
      retValue=handle.getMeasure();
    }
 else     if (handle.getUnits() == DesignChoiceConstants.UNITS_PX) {
      retValue=(handle.getMeasure() * 72d) / dpi;
    }
 else {
      retValue=DimensionUtil.convertTo(handle.getMeasure(),handle.getUnits(),DesignChoiceConstants.UNITS_PT).getMeasure();
    }
  }
  return retValue;
}

Fixed version (ground truth):
/** 
 * Transforms dimension value to points.
 * @param handle
 * @param dpi to convert px unit
 * @return the dimension value with measure of points
 * @since 2.3
 */
public static double convertToPoints(org.eclipse.birt.report.model.api.DimensionHandle handle,int dpi){
  double retValue=0.0;
  if (handle.getMeasure() > 0 && handle.getUnits().trim().length() > 0) {
    if (DesignChoiceConstants.UNITS_PT.equalsIgnoreCase(handle.getUnits())) {
      retValue=handle.getMeasure();
    }
 else     if (DesignChoiceConstants.UNITS_PX.equalsIgnoreCase(handle.getUnits())) {
      retValue=(handle.getMeasure() * 72d) / dpi;
    }
 else {
      retValue=DimensionUtil.convertTo(handle.getMeasure(),handle.getUnits(),DesignChoiceConstants.UNITS_PT).getMeasure();
    }
  }
  return retValue;
}
Program: 65010
Project: 65010
Buggy source:
private EngineConfig getEngineConfig(ModuleHandle handle){
  EngineConfig ec=new EngineConfig();
  ClassLoader parent=Thread.currentThread().getContextClassLoader();
  if (parent == null) {
    parent=this.getClass().getClassLoader();
  }
  ClassLoader customClassLoader=DataSetProvider.getCustomScriptClassLoader(parent,handle);
  ec.getAppContext().put(EngineConstants.APPCONTEXT_CLASSLOADER_KEY,customClassLoader);
  return ec;
}

Fixed version (ground truth):
private EngineConfig getEngineConfig(ModuleHandle handle){
  EngineConfig ec=new EngineConfig();
  ClassLoader parent=Thread.currentThread().getContextClassLoader();
  if (parent == null) {
    parent=this.getClass().getClassLoader();
  }
  ClassLoader customClassLoader=DataSetProvider.getCustomScriptClassLoader(parent,handle);
  return ec;
}
Program: 65011
Project: 65011
Buggy source:
/** 
 * @param parent A widget which will be the parent of the new instance (cannot be null)
 * @param style The style of widget to construct
 */
public void buildUI(Composite parent){
  super.buildUI(parent);
  container.setLayout(WidgetUtil.createGridLayout(2,15));
  IDescriptorProvider provider=new TextPropertyDescriptorProvider(ImageHandle.ALT_TEXT_PROP,ReportDesignConstants.IMAGE_ITEM);
  TextSection section=new TextSection(provider.getDisplayName(),container,true);
  section.setProvider(provider);
  section.setStyle(SWT.SINGLE);
  section.setWidth(500);
  addSection(PageSectionId.ALTER_ALT_TEXT,section);
  IDescriptorProvider keyProvider=new TextPropertyDescriptorProvider(ImageHandle.ALT_TEXT_KEY_PROP,ReportDesignConstants.IMAGE_ITEM);
  TextSection keySection=new TextSection(keyProvider.getDisplayName(),container,true);
  keySection.setProvider(keyProvider);
  keySection.setStyle(SWT.SINGLE);
  keySection.setWidth(500);
  addSection(PageSectionId.ALTER_ALT_TEXT_KEY,keySection);
  createSections();
  layoutSections();
}

Fixed version (ground truth):
/** 
 * @param parent A widget which will be the parent of the new instance (cannot be null)
 * @param style The style of widget to construct
 */
public void buildUI(Composite parent){
  super.buildUI(parent);
  container.setLayout(WidgetUtil.createGridLayout(2,15));
  IDescriptorProvider provider=new TextPropertyDescriptorProvider(IImageItemModel.ALT_TEXT_PROP,ReportDesignConstants.IMAGE_ITEM);
  TextSection section=new TextSection(provider.getDisplayName(),container,true);
  section.setProvider(provider);
  section.setStyle(SWT.SINGLE);
  section.setWidth(500);
  addSection(PageSectionId.ALTER_ALT_TEXT,section);
  IDescriptorProvider keyProvider=new TextPropertyDescriptorProvider(IImageItemModel.ALT_TEXT_KEY_PROP,ReportDesignConstants.IMAGE_ITEM);
  TextSection keySection=new TextSection(keyProvider.getDisplayName(),container,true);
  keySection.setProvider(keyProvider);
  keySection.setStyle(SWT.SINGLE);
  keySection.setWidth(500);
  addSection(PageSectionId.ALTER_ALT_TEXT_KEY,keySection);
  createSections();
  layoutSections();
}
Program: 65012
Project: 65012
Buggy source:
public String getWorkSpace(){
  return "String_Node_Str";
}

Fixed version (ground truth):
@Override public String getWorkSpace(){
  return "String_Node_Str";
}
Program: 65013
Project: 65013
Buggy source:
/** 
 * Run all test cases here
 */
public static Test suite(){
  TestSuite suite=new TestSuite("String_Node_Str");
  suite.addTestSuite(MultiPass_FilterTest.class);
  suite.addTestSuite(MultiPass_NestedQueryTest.class);
  suite.addTestSuite(MultiPass_SortTest.class);
  suite.addTestSuite(MultiPassTest.class);
  return suite;
}

Fixed version (ground truth):
/** 
 * Run all test cases here
 */
public static Test suite(){
  TestSuite suite=new TestSuite("String_Node_Str");
  suite.addTestSuite(MultiPass_FilterTest.class);
  suite.addTestSuite(MultiPass_SortTest.class);
  suite.addTestSuite(MultiPassTest.class);
  return suite;
}