Skip to content

Commit bf3206a

Browse files
author
xiezhineng
committed
RBF: fix code
1 parent eccb334 commit bf3206a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

hadoop-hdfs-project/hadoop-hdfs-rbf/src/main/java/org/apache/hadoop/hdfs/server/federation/router/RouterClientProtocol.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,7 @@ public boolean rename(final String src, final String dst)
614614
new Class<?>[] {String.class, String.class},
615615
new RemoteParam(), dstParam);
616616
if (isMultiDestDirectory(src)) {
617-
if (locs.size() == srcLocations.size()) {
617+
if (locs.size() != srcLocations.size()) {
618618
throw new IOException(
619619
"Rename of " + src + " to " + dst + " is not allowed," +
620620
" The remote location should be exactly same.");
@@ -646,7 +646,7 @@ public void rename2(final String src, final String dst,
646646
new Class<?>[] {String.class, String.class, options.getClass()},
647647
new RemoteParam(), dstParam, options);
648648
if (isMultiDestDirectory(src)) {
649-
if (locs.size() == srcLocations.size()) {
649+
if (locs.size() != srcLocations.size()) {
650650
throw new IOException(
651651
"Rename of " + src + " to " + dst + " is not allowed," +
652652
" The remote location should be exactly same.");

0 commit comments

Comments
 (0)