Program: 56229
Project: 56229
Buggy source:
@Override public void run(){
  try {
    updateProgressListener(EProgressState.LOADING,0.1f);
    String replayFilename="String_Node_Str" + logDateFormat.format(new Date()) + "String_Node_Str"+ mapcreator.getMapName()+ "String_Node_Str";
    OutputStream replayFileStream=ResourceManager.writeFile(replayFilename);
    IGameClock gameClock=MatchConstants.clock=taskScheduler.getGameClock();
    gameClock.setReplayLogfile(replayFileStream);
    RandomSingleton.load(randomSeed);
    updateProgressListener(EProgressState.LOADING_MAP,0.3f);
    Thread imagePreloader=ImageProvider.getInstance().startPreloading();
    mainGrid=mapcreator.getMainGrid(playerNumber);
    UIState uiState=mapcreator.getUISettings(playerNumber);
    updateProgressListener(EProgressState.LOADING_IMAGES,0.7f);
    statistics=new GameStatistics(gameClock);
    mainGrid.startThreads();
    imagePreloader.join();
    waitForStartingGameListener();
    final MapInterfaceConnector connector=startingGameListener.startFinished(this);
    connector.loadUIState(uiState.getUiStateData());
    GuiInterface guiInterface=new GuiInterface(connector,gameClock,taskScheduler,mainGrid.getGuiInputGrid(),this,playerNumber,multiplayer);
    gameClock.startExecution();
synchronized (stopMutex) {
      while (!stopped) {
        try {
          stopMutex.wait();
        }
 catch (        InterruptedException e) {
        }
      }
    }
    gameClock.stopExecution();
    connector.stop();
    mainGrid.stopThreads();
    guiInterface.stop();
    Timer100Milli.stop();
    MovableTimer.stop();
    PartitionManagerTimer.stop();
    NewMovable.dropAllMovables();
    Building.dropAllBuildings();
  }
 catch (  MapLoadException e) {
    e.printStackTrace();
    reportFail(EGameError.MAPLOADING_ERROR,e);
  }
catch (  Exception e) {
    e.printStackTrace();
    reportFail(EGameError.UNKNOWN_ERROR,e);
  }
  if (exitListener != null) {
    exitListener.gameExited(this);
  }
}

Fixed version (ground truth):
@Override public void run(){
  try {
    updateProgressListener(EProgressState.LOADING,0.1f);
    String replayFilename="String_Node_Str" + logDateFormat.format(new Date()) + "String_Node_Str"+ mapcreator.getMapName()+ "String_Node_Str";
    OutputStream replayFileStream=ResourceManager.writeFile(replayFilename);
    IGameClock gameClock=MatchConstants.clock=taskScheduler.getGameClock();
    gameClock.setReplayLogfile(replayFileStream);
    RandomSingleton.load(randomSeed);
    updateProgressListener(EProgressState.LOADING_MAP,0.3f);
    Thread imagePreloader=ImageProvider.getInstance().startPreloading();
    mainGrid=mapcreator.getMainGrid(playerNumber);
    UIState uiState=mapcreator.getUISettings(playerNumber);
    updateProgressListener(EProgressState.LOADING_IMAGES,0.7f);
    statistics=new GameStatistics(gameClock);
    mainGrid.startThreads();
    imagePreloader.join();
    waitForStartingGameListener();
    final MapInterfaceConnector connector=startingGameListener.startFinished(this);
    connector.loadUIState(uiState.getUiStateData());
    GuiInterface guiInterface=new GuiInterface(connector,gameClock,taskScheduler,mainGrid.getGuiInputGrid(),this,playerNumber,multiplayer);
    gameClock.startExecution();
synchronized (stopMutex) {
      while (!stopped) {
        try {
          stopMutex.wait();
        }
 catch (        InterruptedException e) {
        }
      }
    }
    taskScheduler.shutdown();
    gameClock.stopExecution();
    connector.stop();
    mainGrid.stopThreads();
    guiInterface.stop();
    Timer100Milli.stop();
    MovableTimer.stop();
    PartitionManagerTimer.stop();
    NewMovable.dropAllMovables();
    Building.dropAllBuildings();
  }
 catch (  MapLoadException e) {
    e.printStackTrace();
    reportFail(EGameError.MAPLOADING_ERROR,e);
  }
catch (  Exception e) {
    e.printStackTrace();
    reportFail(EGameError.UNKNOWN_ERROR,e);
  }
  if (exitListener != null) {
    exitListener.gameExited(this);
  }
}