HADOOP-15289. FileStatus.readFields() assertion incorrect.
Contributed by Steve Loughran.
(cherry picked from commit 12ecb55ffe
)
This commit is contained in:
parent
4df200bc6d
commit
a5cb7f3616
|
@ -458,7 +458,7 @@ public class FileStatus implements Writable, Comparable<Object>,
|
|||
setSymlink((other.isSymlink() ? other.getSymlink() : null));
|
||||
setPath(other.getPath());
|
||||
attr = flags(other.hasAcl(), other.isEncrypted(), other.isErasureCoded());
|
||||
assert (isDirectory() && getSymlink() == null) || !isDirectory();
|
||||
assert !(isDirectory() && isSymlink()) : "A directory cannot be a symlink";
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue