HADOOP-10228. Merging change r1557236 from trunk to branch-2.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1558146 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
56e4457d22
commit
a1d511639f
|
@ -133,6 +133,9 @@ Release 2.4.0 - UNRELEASED
|
||||||
HADOOP-10173. Remove UGI from DIGEST-MD5 SASL server creation (daryn via
|
HADOOP-10173. Remove UGI from DIGEST-MD5 SASL server creation (daryn via
|
||||||
kihwal)
|
kihwal)
|
||||||
|
|
||||||
|
HADOOP-10228. FsPermission#fromShort() should cache FsAction.values().
|
||||||
|
(Haohui Mai via cnauroth)
|
||||||
|
|
||||||
BUG FIXES
|
BUG FIXES
|
||||||
|
|
||||||
HADOOP-9964. Fix deadlocks in TestHttpServer by synchronize
|
HADOOP-9964. Fix deadlocks in TestHttpServer by synchronize
|
||||||
|
|
|
@ -120,8 +120,7 @@ public class FsPermission implements Writable {
|
||||||
}
|
}
|
||||||
|
|
||||||
public void fromShort(short n) {
|
public void fromShort(short n) {
|
||||||
FsAction[] v = FsAction.values();
|
FsAction[] v = FSACTION_VALUES;
|
||||||
|
|
||||||
set(v[(n >>> 6) & 7], v[(n >>> 3) & 7], v[n & 7], (((n >>> 9) & 1) == 1) );
|
set(v[(n >>> 6) & 7], v[(n >>> 3) & 7], v[n & 7], (((n >>> 9) & 1) == 1) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -210,6 +209,8 @@ public class FsPermission implements Writable {
|
||||||
public static final int DEFAULT_UMASK =
|
public static final int DEFAULT_UMASK =
|
||||||
CommonConfigurationKeys.FS_PERMISSIONS_UMASK_DEFAULT;
|
CommonConfigurationKeys.FS_PERMISSIONS_UMASK_DEFAULT;
|
||||||
|
|
||||||
|
private static final FsAction[] FSACTION_VALUES = FsAction.values();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the user file creation mask (umask)
|
* Get the user file creation mask (umask)
|
||||||
*
|
*
|
||||||
|
|
Loading…
Reference in New Issue