Program: 20768
Project: 20768
Buggy source:
private boolean checkChecksum(Map checksumMap,String path,Wagon wagon,String repositoryCachePath) throws ProxyException {
  releaseChecksumListeners(wagon,checksumMap);
  for (Iterator checksums=checksumMap.keySet().iterator(); checksums.hasNext(); ) {
    String checksumExt=(String)checksums.next();
    ChecksumObserver checksum=(ChecksumObserver)checksumMap.get(checksumExt);
    String checksumPath=path + "String_Node_Str" + checksumExt;
    File checksumFile=new File(repositoryCachePath,checksumPath);
    try {
      File tempChecksumFile=new File(checksumFile.getAbsolutePath() + "String_Node_Str");
      wagon.get(checksumPath,tempChecksumFile);
      String remoteChecksum=FileUtils.fileRead(tempChecksumFile).trim();
      if (remoteChecksum.indexOf(' ') > 0) {
        remoteChecksum=remoteChecksum.substring(0,remoteChecksum.indexOf(' '));
      }
      String actualChecksum=checksum.getActualChecksum().toUpperCase();
      remoteChecksum=remoteChecksum.toUpperCase();
      boolean checksumCheck;
      if (remoteChecksum.equals(actualChecksum)) {
        moveTempToTarget(tempChecksumFile,checksumFile);
        checksumCheck=true;
      }
 else {
        getLogger().warn("String_Node_Str" + actualChecksum + "String_Node_Str"+ remoteChecksum);
        checksumCheck=false;
      }
      return checksumCheck;
    }
 catch (    TransferFailedException e) {
      getLogger().warn("String_Node_Str" + checksumPath + "String_Node_Str"+ e.getMessage(),e);
    }
catch (    ResourceDoesNotExistException e) {
      getLogger().debug("String_Node_Str" + checksumPath,e);
    }
catch (    AuthorizationException e) {
      getLogger().warn("String_Node_Str" + checksumPath + "String_Node_Str"+ e.getMessage(),e);
    }
catch (    IOException e) {
      getLogger().warn("String_Node_Str",e);
      return false;
    }
  }
  getLogger().debug("String_Node_Str");
  return true;
}

Fixed version (ground truth):
private boolean checkChecksum(Map checksumMap,String path,Wagon wagon,String repositoryCachePath) throws ProxyException {
  releaseChecksumListeners(wagon,checksumMap);
  boolean correctChecksum=false;
  boolean allNotFound=true;
  for (Iterator i=checksumMap.keySet().iterator(); i.hasNext() && !correctChecksum; ) {
    String checksumExt=(String)i.next();
    ChecksumObserver checksum=(ChecksumObserver)checksumMap.get(checksumExt);
    String checksumPath=path + "String_Node_Str" + checksumExt;
    File checksumFile=new File(repositoryCachePath,checksumPath);
    File tempChecksumFile=new File(checksumFile.getAbsolutePath() + "String_Node_Str");
    tempChecksumFile.deleteOnExit();
    try {
      wagon.get(checksumPath,tempChecksumFile);
      allNotFound=false;
      String remoteChecksum=DigestUtils.cleanChecksum(FileUtils.fileRead(tempChecksumFile),checksumExt.toUpperCase(),path.substring(path.lastIndexOf('/')));
      String actualChecksum=checksum.getActualChecksum().toUpperCase();
      remoteChecksum=remoteChecksum.toUpperCase();
      if (remoteChecksum.equals(actualChecksum)) {
        moveTempToTarget(tempChecksumFile,checksumFile);
        correctChecksum=true;
      }
 else {
        getLogger().warn("String_Node_Str" + actualChecksum + "String_Node_Str"+ remoteChecksum);
      }
    }
 catch (    TransferFailedException e) {
      getLogger().warn("String_Node_Str" + checksumPath + "String_Node_Str"+ e.getMessage(),e);
      allNotFound=false;
    }
catch (    ResourceDoesNotExistException e) {
      getLogger().debug("String_Node_Str" + checksumPath,e);
      if (checksumFile.exists()) {
        checksumFile.delete();
      }
    }
catch (    AuthorizationException e) {
      getLogger().warn("String_Node_Str" + checksumPath + "String_Node_Str"+ e.getMessage(),e);
      allNotFound=false;
    }
catch (    IOException e) {
      getLogger().warn("String_Node_Str",e);
      allNotFound=false;
    }
catch (    DigesterException e) {
      getLogger().warn("String_Node_Str" + checksumPath + "String_Node_Str"+ e.getMessage(),e);
      allNotFound=false;
    }
 finally {
      tempChecksumFile.delete();
    }
  }
  return correctChecksum || allNotFound;
}