svn emrge -c 1373599. FIXES: HADOOP-8703

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1373600 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Joseph Evans 2012-08-15 19:51:16 +00:00
parent 15b9897255
commit e26c63b238
1 changed files with 3 additions and 2 deletions

View File

@ -92,8 +92,9 @@ public class RetriableFileCopyCommand extends RetriableCommand {
compareFileLengths(sourceFileStatus, tmpTargetPath, configuration, bytesRead);
//At this point, src&dest lengths are same. if length==0, we skip checksum
if (bytesRead != 0)
compareCheckSums(sourceFS, sourceFileStatus.getPath(), targetFS, tmpTargetPath);
if (bytesRead != 0) {
compareCheckSums(sourceFS, sourceFileStatus.getPath(), targetFS, tmpTargetPath);
}
promoteTmpToTarget(tmpTargetPath, target, targetFS);
return bytesRead;