nus-yam/ex-repair huggingface dataset:
Program: 161903
Project: 161903
Buggy source:
private void closeHandle(String pid,String handle){
  try {
    ProcessBuilder pb=new ProcessBuilder("String_Node_Str","String_Node_Str",handle,"String_Node_Str",pid,"String_Node_Str");
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    int count=0;
    while ((line=input.readLine()) != null) {
      if (count > 7) {
        log.info("String_Node_Str" + line);
      }
      count++;
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
}

Fixed version (ground truth):
private void closeHandle(String pid,String handle){
  try {
    ProcessBuilder pb=new ProcessBuilder("String_Node_Str","String_Node_Str",handle,"String_Node_Str",pid,"String_Node_Str");
    Process pr=pb.start();
    try (BufferedReader input=newProcessReader(pr)){
      String line;
      int count=0;
      while ((line=input.readLine()) != null) {
        if (count > 7) {
          log.info("String_Node_Str" + line);
        }
        count++;
      }
    }
     pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
}
Program: 161904
Project: 161904
Buggy source:
private String regQuery(String key,String value,int mode){
  String result="String_Node_Str";
  try {
    ProcessBuilder pb=new ProcessBuilder("String_Node_Str","String_Node_Str",key,"String_Node_Str",value);
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      result=result + line + '\n';
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
  try {
    if (mode == 0) {
      return result.substring(result.lastIndexOf("String_Node_Str") + 2,result.indexOf('\n',result.lastIndexOf("String_Node_Str")));
    }
    return result.substring(result.lastIndexOf("String_Node_Str") - 1,result.indexOf('\n',result.lastIndexOf("String_Node_Str")));
  }
 catch (  IndexOutOfBoundsException e) {
    return "String_Node_Str";
  }
}

Fixed version (ground truth):
private String regQuery(String key,String value,int mode){
  StringBuilder result=new StringBuilder();
  try {
    ProcessBuilder pb=new ProcessBuilder("String_Node_Str","String_Node_Str",key,"String_Node_Str",value);
    Process pr=pb.start();
    try (BufferedReader input=newProcessReader(pr)){
      String line;
      while ((line=input.readLine()) != null) {
        result.append(line + '\n');
      }
    }
     pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
  try {
    if (mode == 0) {
      return result.substring(result.lastIndexOf("String_Node_Str") + 2,result.indexOf("String_Node_Str",result.lastIndexOf("String_Node_Str")));
    }
    return result.substring(result.lastIndexOf("String_Node_Str") - 1,result.indexOf("String_Node_Str",result.lastIndexOf("String_Node_Str")));
  }
 catch (  IndexOutOfBoundsException e) {
    return "String_Node_Str";
  }
}
Program: 161905
Project: 161905
Buggy source:
/** 
 * Generate an preview image representing a specified skybox.
 * @param skyboxFilename The filename of the skybox to generate the preview
 * @see #getBuilderVTFCmd(String)
 */
public void generatePreview(String skyboxFilename){
  try {
    ProcessBuilder pb=getBuilderVTFCmd(skyboxFilename);
    log.finer("String_Node_Str" + pb.command());
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      log.finer("String_Node_Str" + line);
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
}

Fixed version (ground truth):
/** 
 * Generate an preview image representing a specified skybox.
 * @param skyboxFilename The filename of the skybox to generate the preview
 * @see #getBuilderVTFCmd(String)
 */
public void generatePreview(String skyboxFilename){
  try {
    ProcessBuilder pb=getBuilderVTFCmd(skyboxFilename);
    log.finer("String_Node_Str" + pb.command());
    Process pr=pb.start();
    try (BufferedReader input=newProcessReader(pr)){
      String line;
      while ((line=input.readLine()) != null) {
        log.finer("String_Node_Str" + line);
      }
    }
     pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
}
Program: 161906
Project: 161906
Buggy source:
/** 
 * List the files of a specified VPK file.
 * @param tfpath The {@link Path} where HL2 main executable for TF2 is located
 * @param vpkpath The <code>Path</code> where the VPK file to search is located
 * @return A {@link List} of <code>String</code>s of all the files inside the specified VPK file.
 */
public List<String> getVpkContents(Path tfpath,Path vpkpath){
  List<String> files=new ArrayList<>();
  try {
    Path vpktool=resolveVpkToolPath(tfpath);
    ProcessBuilder pb=new ProcessBuilder(vpktool.toString(),"String_Node_Str",vpkpath.toString());
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      files.add(line);
    }
    pr.waitFor();
    log.finer("String_Node_Str" + vpkpath.getFileName() + "String_Node_Str"+ files.size()+ "String_Node_Str");
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str" + vpkpath);
  }
  return files;
}

Fixed version (ground truth):
/** 
 * List the files of a specified VPK file.
 * @param tfpath The {@link Path} where HL2 main executable for TF2 is located
 * @param vpkpath The <code>Path</code> where the VPK file to search is located
 * @return A {@link List} of <code>String</code>s of all the files inside the specified VPK file.
 */
public List<String> getVpkContents(Path tfpath,Path vpkpath){
  List<String> files=new ArrayList<>();
  try {
    Path vpktool=resolveVpkToolPath(tfpath);
    ProcessBuilder pb=new ProcessBuilder(vpktool.toString(),"String_Node_Str",vpkpath.toString());
    Process pr=pb.start();
    try (BufferedReader input=newProcessReader(pr)){
      String line;
      while ((line=input.readLine()) != null) {
        files.add(line);
      }
    }
     pr.waitFor();
    log.finer("String_Node_Str" + vpkpath.getFileName() + "String_Node_Str"+ files.size()+ "String_Node_Str");
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str" + vpkpath);
  }
  return files;
}
Program: 161907
Project: 161907
Buggy source:
/** 
 * Stop or kill the TF2 process, whether it's being run from the tool or not.
 * @see #getBuilderTF2ProcessKiller()
 */
public void killTf2Process(){
  try {
    ProcessBuilder pb=getBuilderTF2ProcessKiller();
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      log.fine("String_Node_Str" + line);
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str");
  }
}

Fixed version (ground truth):
/** 
 * Stop or kill the TF2 process, whether it's being run from the tool or not.
 * @see #getBuilderTF2ProcessKiller()
 */
public void killTf2Process(){
  try {
    ProcessBuilder pb=getBuilderTF2ProcessKiller();
    Process pr=pb.start();
    try (BufferedReader input=newProcessReader(pr)){
      String line;
      while ((line=input.readLine()) != null) {
        log.fine("String_Node_Str" + line);
      }
    }
     pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str");
  }
}
Program: 161908
Project: 161908
Buggy source:
private void extractVpkFile(Path tfpath,String vpkname,Path dest,List<String> files){
  List<String> cmds=new ArrayList<>();
  try {
    Path vpktool=resolveVpkToolPath(tfpath);
    cmds.add(vpktool.toString());
    cmds.add("String_Node_Str");
    cmds.add(Paths.get(vpkname).toAbsolutePath().toString());
    cmds.addAll(files);
    ProcessBuilder pb=new ProcessBuilder(cmds);
    pb.directory(dest.toFile());
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      log.fine("String_Node_Str" + line);
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str" + vpkname);
  }
}

Fixed version (ground truth):
private void extractVpkFile(Path tfpath,String vpkname,Path dest,List<String> files){
  List<String> cmds=new ArrayList<>();
  try {
    Path vpktool=resolveVpkToolPath(tfpath);
    cmds.add(vpktool.toString());
    cmds.add("String_Node_Str");
    cmds.add(Paths.get(vpkname).toAbsolutePath().toString());
    cmds.addAll(files);
    ProcessBuilder pb=new ProcessBuilder(cmds);
    pb.directory(dest.toFile());
    Process pr=pb.start();
    try (BufferedReader input=newProcessReader(pr)){
      String line;
      while ((line=input.readLine()) != null) {
        log.fine("String_Node_Str" + line);
      }
    }
     pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str" + vpkname);
  }
}
Program: 161910
Project: 161910
Buggy source:
private void unpackFileFromJar(Path jarpath,String name,Path destpath){
  JarFile jar;
  try {
    jar=new JarFile(jarpath.toFile());
    JarEntry entry=jar.getJarEntry(name);
    if (entry != null) {
      InputStream is=jar.getInputStream(entry);
      FileOutputStream fos=new FileOutputStream(destpath.resolve(name).toFile());
      while (is.available() > 0) {
        fos.write(is.read());
      }
      fos.close();
      is.close();
    }
 else {
      log.warning("String_Node_Str" + name + "String_Node_Str"+ jarpath);
    }
    jar.close();
  }
 catch (  IOException e) {
    log.log(Level.WARNING,"String_Node_Str" + name + "String_Node_Str"+ jarpath,e);
  }
}

Fixed version (ground truth):
private void unpackFileFromJar(Path jarpath,String name,Path destpath){
  JarFile jar;
  try {
    jar=new JarFile(jarpath.toFile());
    JarEntry entry=jar.getJarEntry(name);
    if (entry != null) {
      try (InputStream is=jar.getInputStream(entry);FileOutputStream fos=new FileOutputStream(destpath.resolve(name).toFile())){
        while (is.available() > 0) {
          fos.write(is.read());
        }
      }
 catch (      IOException e) {
        log.warning("String_Node_Str" + e);
      }
    }
 else {
      log.warning("String_Node_Str" + name + "String_Node_Str"+ jarpath);
    }
    jar.close();
  }
 catch (  IOException e) {
    log.log(Level.WARNING,"String_Node_Str" + name + "String_Node_Str"+ jarpath,e);
  }
}
Program: 161913
Project: 161913
Buggy source:
public void movieOffset() throws IOException {
  String lastmovie="String_Node_Str";
  String alias="String_Node_Str";
  try (DirectoryStream<Path> stream=Files.newDirectoryStream(cfg.getMoviePath(),"String_Node_Str")){
    for (    Path moviefile : stream) {
      String filename=moviefile.getFileName().toString();
      lastmovie=(lastmovie.compareTo(filename) > 0 ? lastmovie : filename);
    }
  }
   if (!lastmovie.equals("String_Node_Str")) {
    int idx="String_Node_Str".indexOf(lastmovie.charAt(0));
    if (idx >= 0) {
      alias="String_Node_Str" + (idx + 2);
    }
 else     if (lastmovie.charAt(0) == 'p') {
      alias="String_Node_Str";
    }
  }
  PrintWriter pw=new PrintWriter(new FileWriter("String_Node_Str"));
  pw.println(alias);
  pw.close();
}

Fixed version (ground truth):
public void movieOffset() throws IOException {
  String lastmovie="String_Node_Str";
  String alias="String_Node_Str";
  try (DirectoryStream<Path> stream=Files.newDirectoryStream(cfg.getMoviePath(),"String_Node_Str")){
    for (    Path moviefile : stream) {
      String filename=moviefile.getFileName().toString();
      lastmovie=(lastmovie.compareTo(filename) > 0 ? lastmovie : filename);
    }
  }
   if (!lastmovie.equals("String_Node_Str")) {
    int idx="String_Node_Str".indexOf(lastmovie.charAt(0));
    if (idx >= 0) {
      alias="String_Node_Str" + (idx + 2);
    }
 else     if (lastmovie.charAt(0) == 'p') {
      alias="String_Node_Str";
    }
  }
  Files.write(Paths.get("String_Node_Str"),Arrays.asList(alias),Charset.forName("String_Node_Str"));
}
Program: 161914
Project: 161914
Buggy source:
public void createMovienameCfgs() throws IOException {
  String[] prefixes={"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"};
  String video=cfg.getString(Key.SourceRecorderVideoFormat);
  String audio=cfg.getString(Key.SourceRecorderAudioFormat);
  int quality=cfg.getInt(Key.SourceRecorderJpegQuality);
  for (  String prefix : prefixes) {
    PrintWriter pw=new PrintWriter(new FileWriter("String_Node_Str" + prefix + "String_Node_Str"));
    pw.println("String_Node_Str" + cfg.getMoviePath() + "String_Node_Str"+ prefix+ "String_Node_Str"+ video+ "String_Node_Str"+ audio+ (video.equals("String_Node_Str") ? "String_Node_Str" + quality : "String_Node_Str"));
    pw.close();
  }
}

Fixed version (ground truth):
public void createMovienameCfgs() throws IOException {
  String[] prefixes={"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"};
  String video=cfg.getString(Key.SourceRecorderVideoFormat);
  String audio=cfg.getString(Key.SourceRecorderAudioFormat);
  int quality=cfg.getInt(Key.SourceRecorderJpegQuality);
  for (  String prefix : prefixes) {
    List<String> lines=Arrays.asList("String_Node_Str" + cfg.getMoviePath() + "String_Node_Str"+ prefix+ "String_Node_Str"+ video+ "String_Node_Str"+ audio+ (video.equals("String_Node_Str") ? "String_Node_Str" + quality : "String_Node_Str"));
    Files.write(Paths.get("String_Node_Str" + prefix + "String_Node_Str"),lines,Charset.forName("String_Node_Str"));
  }
}
Program: 161915
Project: 161915
Buggy source:
public abstract void closeHandles(Path path);

Fixed version (ground truth):
/** 
 * Closes all open handles matching this path. This is useful to unlock files that some process can hold preventing the restore/replace file mechanism to work correctly.
 * @param path the directory where handles are being closed
 */
public abstract void closeHandles(Path path);
Program: 161916
Project: 161916
Buggy source:
private Path delete(Path dir) throws IOException {
  return Files.walkFileTree(dir,new DeleteDirVisitor());
}

Fixed version (ground truth):
private Path delete(Path dir) throws IOException {
  return Files.walkFileTree(dir,new DeleteDirVisitor(cl));
}
Program: 161917
Project: 161917
Buggy source:
@Override public FileVisitResult postVisitDirectory(Path dir,IOException exc) throws IOException {
  if (exc == null) {
    try {
      log.finer("String_Node_Str" + dir);
      Files.delete(dir);
    }
 catch (    NoSuchFileException e) {
    }
catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
    }
    return FileVisitResult.CONTINUE;
  }
  throw exc;
}

Fixed version (ground truth):
@Override public FileVisitResult postVisitDirectory(Path dir,IOException exc) throws IOException {
  if (exc == null) {
    try {
      log.finer("String_Node_Str" + dir);
      Files.delete(dir);
    }
 catch (    NoSuchFileException e) {
    }
catch (    DirectoryNotEmptyException e) {
      log.info("String_Node_Str" + dir);
    }
catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
    }
    return FileVisitResult.CONTINUE;
  }
  throw exc;
}
Program: 161918
Project: 161918
Buggy source:
@Override public FileVisitResult visitFile(Path path,BasicFileAttributes attrs) throws IOException {
  try {
    path.toFile().setWritable(true);
    log.finer("String_Node_Str" + path);
    Files.delete(path);
  }
 catch (  NoSuchFileException e) {
  }
catch (  IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
  return FileVisitResult.CONTINUE;
}

Fixed version (ground truth):
@Override public FileVisitResult visitFile(Path path,BasicFileAttributes attrs) throws IOException {
  try {
    path.toFile().setWritable(true);
    log.finer("String_Node_Str" + path);
    Files.delete(path);
  }
 catch (  NoSuchFileException e) {
  }
catch (  IOException e) {
    if (path.endsWith("String_Node_Str") || path.endsWith("String_Node_Str")) {
      log.info("String_Node_Str" + path);
      cl.delete(path);
    }
 else {
      log.log(Level.INFO,"String_Node_Str",e);
    }
  }
  return FileVisitResult.CONTINUE;
}
Program: 161919
Project: 161919
Buggy source:
private String regQuery(String key,String value,int mode){
  String result="String_Node_Str";
  try {
    ProcessBuilder pb=new ProcessBuilder("String_Node_Str","String_Node_Str",key,"String_Node_Str",value);
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      result=result + line + '\n';
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
  if (mode == 0)   return result.substring(result.lastIndexOf("String_Node_Str") + 2,result.indexOf('\n',result.lastIndexOf("String_Node_Str")));
  return result.substring(result.lastIndexOf("String_Node_Str") - 1,result.indexOf('\n',result.lastIndexOf("String_Node_Str")));
}

Fixed version (ground truth):
private String regQuery(String key,String value,int mode){
  String result="String_Node_Str";
  try {
    ProcessBuilder pb=new ProcessBuilder("String_Node_Str","String_Node_Str",key,"String_Node_Str",value);
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      result=result + line + '\n';
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
  try {
    if (mode == 0) {
      return result.substring(result.lastIndexOf("String_Node_Str") + 2,result.indexOf('\n',result.lastIndexOf("String_Node_Str")));
    }
    return result.substring(result.lastIndexOf("String_Node_Str") - 1,result.indexOf('\n',result.lastIndexOf("String_Node_Str")));
  }
 catch (  IndexOutOfBoundsException e) {
    return "String_Node_Str";
  }
}
Program: 161921
Project: 161921
Buggy source:
private TickList generateTickList(int i){
  TickList current;
  current=new TickList((String)model.getValueAt(i,0),Integer.parseInt((String)model.getValueAt(i,1)),Integer.parseInt((String)model.getValueAt(i,2)));
  if (i + 1 == view.getTableTicks().getRowCount())   return current;
  current.setNext(generateTickList(i + 1));
  return current;
}

Fixed version (ground truth):
private TickList generateTickList(int i){
  TickList current;
  current=new TickList((String)model.getValueAt(i,0),(int)model.getValueAt(i,1),(int)model.getValueAt(i,2));
  if (i + 1 == view.getTableTicks().getRowCount())   return current;
  current.setNext(generateTickList(i + 1));
  return current;
}
Program: 161922
Project: 161922
Buggy source:
public CustomPath(Path path,String name,EnumSet<PathContents> contents){
  this.path=path;
  this.name=name;
  this.contents=contents;
}

Fixed version (ground truth):
public CustomPath(Path path,String name,EnumSet<PathContents> contents){
  this.path=path;
  this.name=name;
  this.contents=contents;
  if (contents.contains(PathContents.READONLY)) {
    selected=true;
  }
}
Program: 161924
Project: 161924
Buggy source:
public void restoreAll(){
  Path tfpath=cfg.getTfPath();
  Path customBackupPath=tfpath.resolve("String_Node_Str");
  Path customPath=tfpath.resolve("String_Node_Str");
  Path configBackupPath=tfpath.resolve("String_Node_Str");
  Path configPath=tfpath.resolve("String_Node_Str");
  if (Files.exists(configBackupPath)) {
    log.fine("String_Node_Str");
    try {
      delete(configPath);
    }
 catch (    NoSuchFileException e) {
    }
catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
    }
    try {
      if (isEmpty(configPath)) {
        Files.move(configBackupPath,configPath,StandardCopyOption.REPLACE_EXISTING);
      }
 else {
        showRestoreMessage();
      }
    }
 catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
      showRestoreMessage();
    }
  }
  if (Files.exists(customBackupPath)) {
    log.fine("String_Node_Str");
    try {
      delete(customPath);
    }
 catch (    NoSuchFileException e) {
    }
catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
    }
    try {
      if (isEmpty(customPath)) {
        Files.move(customBackupPath,customPath,StandardCopyOption.REPLACE_EXISTING);
      }
 else {
        showRestoreMessage();
      }
    }
 catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
      showRestoreMessage();
    }
  }
}

Fixed version (ground truth):
public boolean restoreAll(){
  Path tfpath=cfg.getTfPath();
  Path customBackupPath=tfpath.resolve("String_Node_Str");
  Path customPath=tfpath.resolve("String_Node_Str");
  Path configBackupPath=tfpath.resolve("String_Node_Str");
  Path configPath=tfpath.resolve("String_Node_Str");
  boolean restoreComplete=true;
  if (Files.exists(configBackupPath)) {
    log.fine("String_Node_Str");
    try {
      delete(configPath);
    }
 catch (    NoSuchFileException e) {
    }
catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
    }
    try {
      if (isEmpty(configPath)) {
        Files.move(configBackupPath,configPath,StandardCopyOption.REPLACE_EXISTING);
      }
 else {
        restoreComplete=false;
      }
    }
 catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
      restoreComplete=false;
    }
  }
  if (Files.exists(customBackupPath)) {
    log.fine("String_Node_Str");
    try {
      delete(customPath);
    }
 catch (    NoSuchFileException e) {
    }
catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
    }
    try {
      if (isEmpty(customPath)) {
        Files.move(customBackupPath,customPath,StandardCopyOption.REPLACE_EXISTING);
      }
 else {
        restoreComplete=false;
      }
    }
 catch (    IOException e) {
      log.log(Level.INFO,"String_Node_Str",e);
      restoreComplete=false;
    }
  }
  if (!restoreComplete) {
    log.info("String_Node_Str");
    log.info("String_Node_Str");
  }
  return restoreComplete;
}
Program: 161925
Project: 161925
Buggy source:
@Override public void run(){
  view.getBtnStartTf().setEnabled(true);
  view.getBtnStartTf().setText("String_Node_Str");
}

Fixed version (ground truth):
@Override public void run(){
  if (worker != null) {
    view.getProgressBar().setVisible(true);
    view.getProgressBar().setIndeterminate(indeterminate);
    view.getProgressBar().setValue(0);
    worker.addPropertyChangeListener(new PropertyChangeListener(){
      public void propertyChange(      PropertyChangeEvent evt){
        if ("String_Node_Str".equals(evt.getPropertyName())) {
          view.getProgressBar().setValue((Integer)evt.getNewValue());
        }
      }
    }
);
  }
 else {
    view.getProgressBar().setVisible(false);
    view.getProgressBar().setIndeterminate(indeterminate);
    view.getProgressBar().setValue(0);
  }
}
Program: 161926
Project: 161926
Buggy source:
@Override protected Map<String,ImageIcon> doInBackground() throws Exception {
  setCurrentWorker(this);
  view.getProgressBar().setIndeterminate(false);
  setProgress(0);
  final Map<String,ImageIcon> map=new HashMap<>();
  try {
    int i=1;
    for (    String skybox : data) {
      setProgress((int)(100 * ((double)i / data.size())));
      status.fine("String_Node_Str" + skybox);
      String img="String_Node_Str" + skybox + "String_Node_Str";
      if (!Files.exists(Paths.get(img))) {
        String filename=skybox + "String_Node_Str";
        cl.extractIfNeeded(settings.getTfPath(),"String_Node_Str",Paths.get("String_Node_Str"),filename);
        cl.generatePreview(filename);
      }
      ImageIcon icon=createPreviewIcon(img);
      map.put(skybox,icon);
      i++;
    }
  }
 catch (  Exception e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
  return map;
}

Fixed version (ground truth):
@Override protected Void doInBackground() throws Exception {
  try {
    configureSkyboxes(view.getCmbSkybox());
  }
 catch (  Exception e) {
    log.log(Level.INFO,"String_Node_Str",e);
  }
  return null;
}
Program: 161929
Project: 161929
Buggy source:
private void setCurrentWorker(SwingWorker<?,?> worker){
  if (worker != null) {
    view.getProgressBar().setVisible(true);
    view.getProgressBar().setIndeterminate(true);
    view.getProgressBar().setValue(0);
    worker.addPropertyChangeListener(new PropertyChangeListener(){
      public void propertyChange(      PropertyChangeEvent evt){
        if ("String_Node_Str".equals(evt.getPropertyName())) {
          view.getProgressBar().setValue((Integer)evt.getNewValue());
        }
      }
    }
);
  }
 else {
    view.getProgressBar().setVisible(false);
    view.getProgressBar().setIndeterminate(false);
    view.getProgressBar().setValue(0);
  }
}

Fixed version (ground truth):
private void setCurrentWorker(final SwingWorker<?,?> worker,final boolean indeterminate){
  SwingUtilities.invokeLater(new Runnable(){
    @Override public void run(){
      if (worker != null) {
        view.getProgressBar().setVisible(true);
        view.getProgressBar().setIndeterminate(indeterminate);
        view.getProgressBar().setValue(0);
        worker.addPropertyChangeListener(new PropertyChangeListener(){
          public void propertyChange(          PropertyChangeEvent evt){
            if ("String_Node_Str".equals(evt.getPropertyName())) {
              view.getProgressBar().setValue((Integer)evt.getNewValue());
            }
          }
        }
);
      }
 else {
        view.getProgressBar().setVisible(false);
        view.getProgressBar().setIndeterminate(indeterminate);
        view.getProgressBar().setValue(0);
      }
    }
  }
);
}
Program: 161930
Project: 161930
Buggy source:
@Override protected void done(){
  try {
    skyboxMap.putAll(get());
    selectSkyboxFromSettings();
    log.fine("String_Node_Str");
  }
 catch (  CancellationException|InterruptedException|ExecutionException e) {
    log.info("String_Node_Str");
  }
  status.info("String_Node_Str");
  if (!isCancelled()) {
    setCurrentWorker(null);
  }
}

Fixed version (ground truth):
@Override protected void done(){
  selectSkyboxFromSettings();
}
Program: 161932
Project: 161932
Buggy source:
public MovieManager(String dir){
  moviedir=dir;
}

Fixed version (ground truth):
public MovieManager(SettingsManager cfg){
  this.cfg=cfg;
}
Program: 161933
Project: 161933
Buggy source:
public void movieOffset() throws IOException {
  FilenameFilter filter=new FilenameFilter(){
    @Override public boolean accept(    File dir,    String name){
      return name.endsWith("String_Node_Str");
    }
  }
;
  String[] moviefiles=new File(moviedir).list(filter);
  String lastmovie="String_Node_Str";
  String alias="String_Node_Str";
  for (int i=0; i < moviefiles.length; ++i) {
    lastmovie=lastmovie.compareTo(moviefiles[i]) > 0 ? lastmovie : moviefiles[i];
  }
  if (!lastmovie.equals("String_Node_Str")) {
switch (lastmovie.charAt(0)) {
case 'a':
      alias="String_Node_Str";
    break;
case 'b':
  alias="String_Node_Str";
break;
case 'c':
alias="String_Node_Str";
break;
case 'd':
alias="String_Node_Str";
break;
case 'e':
alias="String_Node_Str";
break;
case 'f':
alias="String_Node_Str";
break;
case 'g':
alias="String_Node_Str";
break;
case 'h':
alias="String_Node_Str";
break;
case 'i':
alias="String_Node_Str";
break;
case 'j':
alias="String_Node_Str";
break;
case 'k':
alias="String_Node_Str";
break;
case 'l':
alias="String_Node_Str";
break;
case 'm':
alias="String_Node_Str";
break;
case 'n':
alias="String_Node_Str";
break;
case 'o':
alias="String_Node_Str";
break;
case 'p':
alias="String_Node_Str";
break;
}
}
PrintWriter pw=new PrintWriter(new FileWriter("String_Node_Str"));
pw.println(alias);
pw.close();
}

Fixed version (ground truth):
public void movieOffset() throws IOException {
  String lastmovie="String_Node_Str";
  String alias="String_Node_Str";
  try (DirectoryStream<Path> stream=Files.newDirectoryStream(cfg.getMoviePath(),"String_Node_Str")){
    for (    Path moviefile : stream) {
      String filename=moviefile.getFileName().toString();
      lastmovie=(lastmovie.compareTo(filename) > 0 ? lastmovie : filename);
    }
  }
   if (!lastmovie.equals("String_Node_Str")) {
    int idx="String_Node_Str".indexOf(lastmovie.charAt(0));
    if (idx >= 0) {
      alias="String_Node_Str" + (idx + 2);
    }
 else     if (lastmovie.charAt(0) == 'p') {
      alias="String_Node_Str";
    }
  }
  PrintWriter pw=new PrintWriter(new FileWriter("String_Node_Str"));
  pw.println(alias);
  pw.close();
}
Program: 161934
Project: 161934
Buggy source:
public void createMovienameCfgs() throws IOException {
  String[] letters={"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"};
  String[] numbers={"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"};
  for (int i=0; i < 16; ++i) {
    PrintWriter pw=new PrintWriter(new FileWriter("String_Node_Str" + letters[i] + numbers[i]+ "String_Node_Str"));
    pw.println("String_Node_Str" + moviedir + "String_Node_Str"+ letters[i]+ numbers[i]+ "String_Node_Str");
    pw.close();
  }
}

Fixed version (ground truth):
public void createMovienameCfgs() throws IOException {
  String[] prefixes={"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"};
  for (  String prefix : prefixes) {
    PrintWriter pw=new PrintWriter(new FileWriter("String_Node_Str" + prefix + "String_Node_Str"));
    pw.println("String_Node_Str" + cfg.getMoviePath() + "String_Node_Str"+ prefix+ "String_Node_Str");
    pw.close();
  }
}
Program: 161937
Project: 161937
Buggy source:
@Override public String getSteamPath(){
  return "String_Node_Str";
}

Fixed version (ground truth):
@Override public Path getSteamPath(){
  return Paths.get(System.getProperty("String_Node_Str"),"String_Node_Str");
}
Program: 161938
Project: 161938
Buggy source:
@Override public Path resolveVpkToolPath(Path tfpath){
  return tfpath.resolve("String_Node_Str");
}

Fixed version (ground truth):
@Override public Path resolveVpkToolPath(Path tfpath) throws IOException {
  Path path=tfpath.resolve("String_Node_Str");
  Files.setPosixFilePermissions(path,perms777);
  return path;
}
Program: 161939
Project: 161939
Buggy source:
@Override public ProcessBuilder getBuilderStartTF2(int width,int height,String dxlevel){
  return new ProcessBuilder(getSteamPath() + "String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str",dxlevel + "String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str",width + "String_Node_Str","String_Node_Str",height + "String_Node_Str");
}

Fixed version (ground truth):
@Override public ProcessBuilder getBuilderStartTF2(int width,int height,String dxlevel) throws IOException {
  Path steam=getSteamPath().resolve("String_Node_Str");
  Files.setPosixFilePermissions(steam,perms777);
  return new ProcessBuilder(steam.toString(),"String_Node_Str","String_Node_Str","String_Node_Str",dxlevel + "String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str",width + "String_Node_Str","String_Node_Str",height + "String_Node_Str");
}
Program: 161940
Project: 161940
Buggy source:
@Override public String getSteamPath(){
  return regQuery("String_Node_Str","String_Node_Str",1);
}

Fixed version (ground truth):
@Override public Path getSteamPath(){
  return Paths.get(regQuery("String_Node_Str","String_Node_Str",1));
}
Program: 161941
Project: 161941
Buggy source:
public abstract String getSteamPath();

Fixed version (ground truth):
public abstract Path getSteamPath();
Program: 161942
Project: 161942
Buggy source:
public abstract ProcessBuilder getBuilderStartTF2(int width,int height,String dxlevel);

Fixed version (ground truth):
public abstract ProcessBuilder getBuilderStartTF2(int width,int height,String dxlevel) throws IOException ;
Program: 161943
Project: 161943
Buggy source:
public List<String> getVpkContents(Path tfpath,Path vpkpath){
  Path vpktool=resolveVpkToolPath(tfpath);
  List<String> files=new ArrayList<>();
  try {
    ProcessBuilder pb=new ProcessBuilder(vpktool.toString(),"String_Node_Str",vpkpath.toString());
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      files.add(line);
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str" + vpkpath);
  }
  return files;
}

Fixed version (ground truth):
public List<String> getVpkContents(Path tfpath,Path vpkpath){
  List<String> files=new ArrayList<>();
  try {
    Path vpktool=resolveVpkToolPath(tfpath);
    ProcessBuilder pb=new ProcessBuilder(vpktool.toString(),"String_Node_Str",vpkpath.toString());
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      files.add(line);
    }
    pr.waitFor();
    log.fine("String_Node_Str" + vpkpath.getFileName() + "String_Node_Str"+ files.size()+ "String_Node_Str");
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str" + vpkpath);
  }
  return files;
}
Program: 161944
Project: 161944
Buggy source:
public abstract Path resolveVpkToolPath(Path tfpath);

Fixed version (ground truth):
public abstract Path resolveVpkToolPath(Path tfpath) throws IOException ;
Program: 161945
Project: 161945
Buggy source:
private void extractVpkFile(Path tfpath,String vpkname,Path dest,List<String> files){
  Path vpktool=resolveVpkToolPath(tfpath);
  List<String> cmds=new ArrayList<>();
  try {
    cmds.add(vpktool.toString());
    cmds.add("String_Node_Str");
    cmds.add(Paths.get(vpkname).toAbsolutePath().toString());
    cmds.addAll(files);
    ProcessBuilder pb=new ProcessBuilder(cmds);
    pb.directory(dest.toFile());
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      log.fine("String_Node_Str" + line);
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str" + vpkname);
  }
}

Fixed version (ground truth):
private void extractVpkFile(Path tfpath,String vpkname,Path dest,List<String> files){
  List<String> cmds=new ArrayList<>();
  try {
    Path vpktool=resolveVpkToolPath(tfpath);
    cmds.add(vpktool.toString());
    cmds.add("String_Node_Str");
    cmds.add(Paths.get(vpkname).toAbsolutePath().toString());
    cmds.addAll(files);
    ProcessBuilder pb=new ProcessBuilder(cmds);
    pb.directory(dest.toFile());
    Process pr=pb.start();
    BufferedReader input=new BufferedReader(new InputStreamReader(pr.getInputStream()));
    String line;
    while ((line=input.readLine()) != null) {
      log.fine("String_Node_Str" + line);
    }
    pr.waitFor();
  }
 catch (  InterruptedException|IOException e) {
    log.info("String_Node_Str" + vpkname);
  }
}
Program: 161946
Project: 161946
Buggy source:
public Lawena(){
  String impl=this.getClass().getPackage().getImplementationVersion();
  if (impl != null) {
    version=impl;
  }
  build=getManifestString("String_Node_Str","String_Node_Str" + now("String_Node_Str"));
  String osname=System.getProperty("String_Node_Str");
  if (osname.contains("String_Node_Str")) {
    cl=new CLWindows();
  }
 else   if (osname.contains("String_Node_Str")) {
    cl=new CLLinux();
  }
 else {
    throw new UnsupportedOperationException("String_Node_Str");
  }
  cl.setLookAndFeel();
  settings=new SettingsManager("String_Node_Str");
  oDxlevel=cl.getSystemDxLevel();
  steampath=cl.getSteamPath();
  Path tfpath=settings.getTfPath();
  if (tfpath == null || tfpath.toString().isEmpty()) {
    tfpath=Paths.get(steampath,"String_Node_Str");
  }
  if (!Files.exists(tfpath)) {
    tfpath=getChosenTfPath();
    if (tfpath == null) {
      log.info("String_Node_Str");
      System.exit(1);
    }
  }
  settings.setTfPath(tfpath);
  files=new FileManager(settings,cl);
  Path moviepath=settings.getMoviePath();
  if (moviepath == null || moviepath.toString().isEmpty() || !Files.exists(moviepath)) {
    moviepath=getChosenMoviePath();
    if (moviepath == null) {
      log.info("String_Node_Str");
      System.exit(1);
    }
  }
  movies=new MovieManager(moviepath.toString());
  settings.setMoviePath(moviepath);
  settings.save();
  files.restoreAll();
  customPaths=new CustomPathList();
  files.setCustomPathList(customPaths);
  vdm=new DemoEditor(settings);
}

Fixed version (ground truth):
public Lawena(){
  String impl=this.getClass().getPackage().getImplementationVersion();
  if (impl != null) {
    version=impl;
  }
  build=getManifestString("String_Node_Str","String_Node_Str" + now("String_Node_Str"));
  String osname=System.getProperty("String_Node_Str");
  if (osname.contains("String_Node_Str")) {
    cl=new CLWindows();
  }
 else   if (osname.contains("String_Node_Str")) {
    cl=new CLLinux();
  }
 else {
    throw new UnsupportedOperationException("String_Node_Str");
  }
  cl.setLookAndFeel();
  settings=new SettingsManager("String_Node_Str");
  oDxlevel=cl.getSystemDxLevel();
  steampath=cl.getSteamPath();
  Path tfpath=settings.getTfPath();
  if (tfpath == null || tfpath.toString().isEmpty()) {
    tfpath=steampath.resolve("String_Node_Str");
  }
  if (!Files.exists(tfpath)) {
    tfpath=getChosenTfPath();
    if (tfpath == null) {
      log.info("String_Node_Str");
      System.exit(1);
    }
  }
  settings.setTfPath(tfpath);
  files=new FileManager(settings,cl);
  Path moviepath=settings.getMoviePath();
  if (moviepath == null || moviepath.toString().isEmpty() || !Files.exists(moviepath)) {
    moviepath=getChosenMoviePath();
    if (moviepath == null) {
      log.info("String_Node_Str");
      System.exit(1);
    }
  }
  movies=new MovieManager(moviepath.toString());
  settings.setMoviePath(moviepath);
  settings.save();
  files.restoreAll();
  customPaths=new CustomPathList();
  files.setCustomPathList(customPaths);
  vdm=new DemoEditor(settings);
}
Program: 161947
Project: 161947
Buggy source:
private Path getChosenTfPath(){
  Path selected=null;
  int ret=0;
  while ((selected == null && ret == 0) || (selected != null && (!Files.exists(selected) || !selected.getFileName().equals("String_Node_Str")))) {
    choosedir=new JFileChooser();
    choosedir.setDialogTitle("String_Node_Str");
    choosedir.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
    choosedir.setCurrentDirectory(new File(steampath));
    choosedir.setFileHidingEnabled(false);
    ret=choosedir.showOpenDialog(null);
    if (ret == JFileChooser.APPROVE_OPTION) {
      selected=choosedir.getSelectedFile().toPath();
    }
 else {
      selected=null;
    }
  }
  return selected;
}

Fixed version (ground truth):
private Path getChosenTfPath(){
  Path selected=null;
  int ret=0;
  while ((selected == null && ret == 0) || (selected != null && (!Files.exists(selected)))) {
    choosedir=new JFileChooser();
    choosedir.setDialogTitle("String_Node_Str");
    choosedir.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);
    choosedir.setCurrentDirectory(steampath.toFile());
    choosedir.setFileHidingEnabled(false);
    ret=choosedir.showOpenDialog(null);
    if (ret == JFileChooser.APPROVE_OPTION) {
      selected=choosedir.getSelectedFile().toPath();
    }
 else {
      selected=null;
    }
    log.finer("String_Node_Str" + selected);
  }
  return selected;
}
Program: 161950
Project: 161950
Buggy source:
@Override public FileVisitResult visitFile(Path file,BasicFileAttributes attrs) throws IOException {
  Files.copy(file,toPath.resolve(fromPath.relativize(file)),copyOption);
  return FileVisitResult.CONTINUE;
}

Fixed version (ground truth):
@Override public FileVisitResult visitFile(Path file,BasicFileAttributes attrs) throws IOException {
  Path target=Files.copy(file,toPath.resolve(fromPath.relativize(file)),copyOption);
  target.toFile().setWritable(false);
  return FileVisitResult.CONTINUE;
}
Program: 161951
Project: 161951
Buggy source:
@Override public FileVisitResult postVisitDirectory(Path dir,IOException exc) throws IOException {
  if (exc == null) {
    Files.delete(dir);
    return FileVisitResult.CONTINUE;
  }
  throw exc;
}

Fixed version (ground truth):
@Override public FileVisitResult postVisitDirectory(Path dir,IOException exc) throws IOException {
  if (exc == null) {
    try {
      Files.delete(dir);
    }
 catch (    NoSuchFileException e) {
    }
catch (    IOException e) {
      log.info("String_Node_Str" + e);
    }
    return FileVisitResult.CONTINUE;
  }
  throw exc;
}
Program: 161952
Project: 161952
Buggy source:
@Override public FileVisitResult visitFile(Path file,BasicFileAttributes attrs) throws IOException {
  Files.delete(file);
  return FileVisitResult.CONTINUE;
}

Fixed version (ground truth):
@Override public FileVisitResult visitFile(Path path,BasicFileAttributes attrs) throws IOException {
  try {
    path.toFile().setWritable(true);
    Files.delete(path);
  }
 catch (  NoSuchFileException e) {
  }
catch (  IOException e) {
    log.info("String_Node_Str" + e);
  }
  return FileVisitResult.CONTINUE;
}
Program: 161954
Project: 161954
Buggy source:
public static void main(String[] args) throws Exception {
  SimpleLog sl=new SimpleLog("String_Node_Str");
  sl.startLoggingToConsole();
  try {
    UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
  }
 catch (  Exception e) {
    log.warning("String_Node_Str" + e);
    System.exit(1);
  }
  SwingUtilities.invokeAndWait(new Runnable(){
    public void run(){
      LwrtGUI frame=new LwrtGUI();
      try {
        frame.init();
        Thread.sleep(1000);
      }
 catch (      Exception e) {
        log.warning("String_Node_Str" + e);
      }
      frame.setVisible(true);
    }
  }
);
}

Fixed version (ground truth):
public static void main(String[] args) throws Exception {
  SimpleLog sl=new SimpleLog("String_Node_Str");
  sl.startLoggingToConsole();
  try {
    UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
  }
 catch (  Exception e) {
    log.warning("String_Node_Str" + e);
    System.exit(1);
  }
  Thread.setDefaultUncaughtExceptionHandler(new Thread.UncaughtExceptionHandler(){
    public void uncaughtException(    Thread t,    final Throwable e){
      e.printStackTrace();
    }
  }
);
  SwingUtilities.invokeAndWait(new Runnable(){
    public void run(){
      LwrtGUI frame=new LwrtGUI();
      try {
        frame.init();
        Thread.sleep(1000);
      }
 catch (      Exception e) {
        log.warning("String_Node_Str" + e);
      }
      frame.setVisible(true);
    }
  }
);
}
Program: 161956
Project: 161956
Buggy source:
public void show(){
  frame=new JFrame("String_Node_Str");
  frame.add(this);
  frame.addWindowListener(new PreviewWindowListener());
  frame.setSize(500,500);
  frame.setVisible(true);
  Dimension dim=Toolkit.getDefaultToolkit().getScreenSize();
  int x=(dim.width - 500) / 2;
  int y=(dim.height - 500) / 2;
  frame.setLocation(x - 300,y);
  frame.setResizable(false);
}

Fixed version (ground truth):
public void show(){
  frame=new JFrame("String_Node_Str");
  frame.add(this);
  frame.addWindowListener(new WindowAdapter(){
    @Override public void windowClosing(    WindowEvent e){
      JFrame frame=(JFrame)(e.getWindow());
      frame.dispose();
    }
  }
);
  frame.setSize(500,500);
  frame.setVisible(true);
  Dimension dim=Toolkit.getDefaultToolkit().getScreenSize();
  int x=(dim.width - 500) / 2;
  int y=(dim.height - 500) / 2;
  frame.setLocation(x - 300,y);
  frame.setResizable(false);
}
Program: 161961
Project: 161961
Buggy source:
void fillFontPop(){
  List<Map> fontArray=MMPController.fontArray;
  for (  Map currMap : fontArray) {
    if (currMap.get("String_Node_Str") != null) {
      String fontName=(String)currMap.get("String_Node_Str");
      propLabelFontBox.addItem(fontName);
    }
  }
  List<String> androidFontNameArray=MMPController.androidFontNameArray;
  for (  String currFontName : androidFontNameArray) {
    propLabelAndroidFontTypeBox.addItem(currFontName);
  }
}

Fixed version (ground truth):
void fillFontPop(){
  List<Map> fontArray=MMPController.fontArray;
  for (  Map currMap : fontArray) {
    if (currMap.get("String_Node_Str") != null) {
      String fontName=(String)currMap.get("String_Node_Str");
      propLabelFontBox.addItem(fontName);
    }
  }
  List<String> androidFontFileNameArray=MMPController.androidFontFileArray;
  for (  String currFontFileName : androidFontFileNameArray) {
    propLabelAndroidFontTypeBox.addItem(currFontFileName);
  }
}
Program: 161962
Project: 161962
Buggy source:
public MMPLabel(Rectangle frame){
  super();
  address="String_Node_Str";
  fontFamily="String_Node_Str";
  fontName="String_Node_Str";
  androidFontName="String_Node_Str";
  textSize=16;
  stringValue="String_Node_Str";
  setLayout(null);
  overPanel=new JPanel();
  overPanel.setOpaque(false);
  add(overPanel);
  textView=new JTextArea(stringValue);
  textView.setForeground(color);
  textView.setFont(new Font(DEFAULT_FONT,Font.PLAIN,textSize));
  textView.setOpaque(false);
  textView.setBackground(new Color(0,0,0,0));
  textView.setBorder(BorderFactory.createEmptyBorder());
  textView.setWrapStyleWord(true);
  textView.setLineWrap(true);
  textView.setEditable(false);
  for (  MouseListener ml : textView.getMouseListeners())   textView.removeMouseListener(ml);
  for (  MouseMotionListener ml : textView.getMouseMotionListeners())   textView.removeMouseMotionListener(ml);
  add(textView);
  this.setColor(this.color);
  this.setBounds(frame);
  overPanel.addMouseListener(this);
  overPanel.addMouseMotionListener(this);
}

Fixed version (ground truth):
public MMPLabel(Rectangle frame){
  super();
  address="String_Node_Str";
  fontFamily="String_Node_Str";
  fontName="String_Node_Str";
  androidFontFileName="String_Node_Str";
  androidFontName=MMPController.androidFontFileToNameMap.get(androidFontFileName);
  textSize=16;
  stringValue="String_Node_Str";
  setLayout(null);
  overPanel=new JPanel();
  overPanel.setOpaque(false);
  add(overPanel);
  textView=new JTextArea(stringValue);
  textView.setForeground(color);
  textView.setFont(new Font(DEFAULT_FONT,Font.PLAIN,textSize));
  textView.setOpaque(false);
  textView.setBackground(new Color(0,0,0,0));
  textView.setBorder(BorderFactory.createEmptyBorder());
  textView.setWrapStyleWord(true);
  textView.setLineWrap(true);
  textView.setEditable(false);
  for (  MouseListener ml : textView.getMouseListeners())   textView.removeMouseListener(ml);
  for (  MouseMotionListener ml : textView.getMouseMotionListeners())   textView.removeMouseMotionListener(ml);
  add(textView);
  this.setColor(this.color);
  this.setBounds(frame);
  overPanel.addMouseListener(this);
  overPanel.addMouseMotionListener(this);
}