Program: 12057
Project: 12057
Buggy source:
private void initialize(){
  AbstractMethodDeclaration methodObject1=this.mapper.getPDG1().getMethod();
  AbstractMethodDeclaration methodObject2=this.mapper.getPDG2().getMethod();
  MethodDeclaration methodDeclaration1=methodObject1.getMethodDeclaration();
  MethodDeclaration methodDeclaration2=methodObject2.getMethodDeclaration();
  this.sourceCompilationUnits=new ArrayList<CompilationUnit>();
  this.sourceTypeDeclarations=new ArrayList<TypeDeclaration>();
  this.sourceMethodDeclarations=new ArrayList<MethodDeclaration>();
  this.removableStatements=new ArrayList<TreeSet<PDGNode>>();
  removableStatements.add(this.mapper.getRemovableNodesG1());
  removableStatements.add(this.mapper.getRemovableNodesG2());
  this.remainingStatementsMovableBefore=new ArrayList<TreeSet<PDGNode>>();
  remainingStatementsMovableBefore.add(this.mapper.getNonMappedPDGNodesG1MovableBefore());
  remainingStatementsMovableBefore.add(this.mapper.getNonMappedPDGNodesG2MovableBefore());
  this.remainingStatementsMovableAfter=new ArrayList<TreeSet<PDGNode>>();
  remainingStatementsMovableAfter.add(this.mapper.getNonMappedPDGNodesG1MovableAfter());
  remainingStatementsMovableAfter.add(this.mapper.getNonMappedPDGNodesG2MovableAfter());
  this.returnedVariables=new ArrayList<ArrayList<VariableDeclaration>>();
  returnedVariables.add(new ArrayList<VariableDeclaration>(this.mapper.getDeclaredVariablesInMappedNodesUsedByNonMappedNodesG1()));
  returnedVariables.add(new ArrayList<VariableDeclaration>(this.mapper.getDeclaredVariablesInMappedNodesUsedByNonMappedNodesG2()));
  this.fieldDeclarationsToBePulledUp=new ArrayList<Set<VariableDeclaration>>();
  this.fieldDeclarationsToBeParameterized=new ArrayList<Set<VariableDeclaration>>();
  this.methodDeclarationsToBePulledUp=new ArrayList<Set<MethodDeclaration>>();
  this.labeledStatementsToBeRemoved=new ArrayList<Set<LabeledStatement>>();
  for (int i=0; i < 2; i++) {
    fieldDeclarationsToBePulledUp.add(new LinkedHashSet<VariableDeclaration>());
    fieldDeclarationsToBeParameterized.add(new LinkedHashSet<VariableDeclaration>());
    methodDeclarationsToBePulledUp.add(new LinkedHashSet<MethodDeclaration>());
    labeledStatementsToBeRemoved.add(new LinkedHashSet<LabeledStatement>());
  }
  this.compilationUnitChanges=new LinkedHashMap<ICompilationUnit,CompilationUnitChange>();
  this.createCompilationUnitChanges=new LinkedHashMap<ICompilationUnit,CreateCompilationUnitChange>();
  this.javaElementsToOpenInEditor=new LinkedHashSet<IJavaElement>();
  this.sourceMethodDeclarations.add(methodDeclaration1);
  this.sourceMethodDeclarations.add(methodDeclaration2);
  this.sourceTypeDeclarations.add((TypeDeclaration)methodDeclaration1.getParent());
  this.sourceTypeDeclarations.add((TypeDeclaration)methodDeclaration2.getParent());
  this.sourceCompilationUnits.add((CompilationUnit)methodDeclaration1.getRoot());
  this.sourceCompilationUnits.add((CompilationUnit)methodDeclaration2.getRoot());
  this.originalPassedParameters=new LinkedHashMap<VariableBindingKeyPair,ArrayList<VariableDeclaration>>();
  this.parameterizedDifferenceMap=new LinkedHashMap<BindingSignaturePair,ASTNodeDifference>();
  this.sortedNodeMappings=new TreeSet<PDGNodeMapping>(this.mapper.getMaximumStateWithMinimumDifferences().getNodeMappings());
  for (  PDGNodeMapping pdgNodeMapping : sortedNodeMappings) {
    PDGNode pdgNode=pdgNodeMapping.getNodeG1();
    CFGNode cfgNode=pdgNode.getCFGNode();
    if (cfgNode instanceof CFGBranchDoLoopNode) {
      CFGBranchDoLoopNode cfgDoLoopNode=(CFGBranchDoLoopNode)cfgNode;
      doLoopNodes.add(cfgDoLoopNode);
    }
  }
  for (  CompilationUnit sourceCompilationUnit : sourceCompilationUnits) {
    ICompilationUnit sourceICompilationUnit=(ICompilationUnit)sourceCompilationUnit.getJavaElement();
    MultiTextEdit sourceMultiTextEdit=new MultiTextEdit();
    CompilationUnitChange sourceCompilationUnitChange=new CompilationUnitChange("String_Node_Str",sourceICompilationUnit);
    sourceCompilationUnitChange.setEdit(sourceMultiTextEdit);
    compilationUnitChanges.put(sourceICompilationUnit,sourceCompilationUnitChange);
  }
  this.cloneInfo=null;
}

Fixed version (ground truth):
private void initialize(){
  AbstractMethodDeclaration methodObject1=this.mapper.getPDG1().getMethod();
  AbstractMethodDeclaration methodObject2=this.mapper.getPDG2().getMethod();
  MethodDeclaration methodDeclaration1=methodObject1.getMethodDeclaration();
  MethodDeclaration methodDeclaration2=methodObject2.getMethodDeclaration();
  this.sourceCompilationUnits=new ArrayList<CompilationUnit>();
  this.sourceTypeDeclarations=new ArrayList<TypeDeclaration>();
  this.sourceMethodDeclarations=new ArrayList<MethodDeclaration>();
  this.removableStatements=new ArrayList<TreeSet<PDGNode>>();
  removableStatements.add(this.mapper.getRemovableNodesG1());
  removableStatements.add(this.mapper.getRemovableNodesG2());
  this.remainingStatementsMovableBefore=new ArrayList<TreeSet<PDGNode>>();
  remainingStatementsMovableBefore.add(this.mapper.getNonMappedPDGNodesG1MovableBefore());
  remainingStatementsMovableBefore.add(this.mapper.getNonMappedPDGNodesG2MovableBefore());
  this.remainingStatementsMovableAfter=new ArrayList<TreeSet<PDGNode>>();
  remainingStatementsMovableAfter.add(this.mapper.getNonMappedPDGNodesG1MovableAfter());
  remainingStatementsMovableAfter.add(this.mapper.getNonMappedPDGNodesG2MovableAfter());
  this.returnedVariables=new ArrayList<ArrayList<VariableDeclaration>>();
  returnedVariables.add(new ArrayList<VariableDeclaration>(this.mapper.getVariablesToBeReturnedG1()));
  returnedVariables.add(new ArrayList<VariableDeclaration>(this.mapper.getVariablesToBeReturnedG2()));
  this.fieldDeclarationsToBePulledUp=new ArrayList<Set<VariableDeclaration>>();
  this.fieldDeclarationsToBeParameterized=new ArrayList<Set<VariableDeclaration>>();
  this.methodDeclarationsToBePulledUp=new ArrayList<Set<MethodDeclaration>>();
  this.labeledStatementsToBeRemoved=new ArrayList<Set<LabeledStatement>>();
  for (int i=0; i < 2; i++) {
    fieldDeclarationsToBePulledUp.add(new LinkedHashSet<VariableDeclaration>());
    fieldDeclarationsToBeParameterized.add(new LinkedHashSet<VariableDeclaration>());
    methodDeclarationsToBePulledUp.add(new LinkedHashSet<MethodDeclaration>());
    labeledStatementsToBeRemoved.add(new LinkedHashSet<LabeledStatement>());
  }
  this.compilationUnitChanges=new LinkedHashMap<ICompilationUnit,CompilationUnitChange>();
  this.createCompilationUnitChanges=new LinkedHashMap<ICompilationUnit,CreateCompilationUnitChange>();
  this.javaElementsToOpenInEditor=new LinkedHashSet<IJavaElement>();
  this.sourceMethodDeclarations.add(methodDeclaration1);
  this.sourceMethodDeclarations.add(methodDeclaration2);
  this.sourceTypeDeclarations.add((TypeDeclaration)methodDeclaration1.getParent());
  this.sourceTypeDeclarations.add((TypeDeclaration)methodDeclaration2.getParent());
  this.sourceCompilationUnits.add((CompilationUnit)methodDeclaration1.getRoot());
  this.sourceCompilationUnits.add((CompilationUnit)methodDeclaration2.getRoot());
  this.originalPassedParameters=new LinkedHashMap<VariableBindingKeyPair,ArrayList<VariableDeclaration>>();
  this.parameterizedDifferenceMap=new LinkedHashMap<BindingSignaturePair,ASTNodeDifference>();
  this.sortedNodeMappings=new TreeSet<PDGNodeMapping>(this.mapper.getMaximumStateWithMinimumDifferences().getNodeMappings());
  for (  PDGNodeMapping pdgNodeMapping : sortedNodeMappings) {
    PDGNode pdgNode=pdgNodeMapping.getNodeG1();
    CFGNode cfgNode=pdgNode.getCFGNode();
    if (cfgNode instanceof CFGBranchDoLoopNode) {
      CFGBranchDoLoopNode cfgDoLoopNode=(CFGBranchDoLoopNode)cfgNode;
      doLoopNodes.add(cfgDoLoopNode);
    }
  }
  for (  CompilationUnit sourceCompilationUnit : sourceCompilationUnits) {
    ICompilationUnit sourceICompilationUnit=(ICompilationUnit)sourceCompilationUnit.getJavaElement();
    MultiTextEdit sourceMultiTextEdit=new MultiTextEdit();
    CompilationUnitChange sourceCompilationUnitChange=new CompilationUnitChange("String_Node_Str",sourceICompilationUnit);
    sourceCompilationUnitChange.setEdit(sourceMultiTextEdit);
    compilationUnitChanges.put(sourceICompilationUnit,sourceCompilationUnitChange);
  }
  this.cloneInfo=null;
}