mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-24 11:27:49 +00:00
In setAttributes(int,...) mask out unused attributes bits in the same as setAttributes(String,...) does
This commit is contained in:
parent
634531d68c
commit
ab6d7edc2f
@ -467,6 +467,8 @@ public abstract class ScriptableObject implements Scriptable, Serializable,
|
||||
int attributes)
|
||||
throws PropertyException
|
||||
{
|
||||
final int mask = READONLY | DONTENUM | PERMANENT;
|
||||
attributes &= mask; // mask out unused bits
|
||||
Slot slot = getSlot(null, index, false);
|
||||
if (slot == null) {
|
||||
throw PropertyException.withMessage0("msg.prop.not.found");
|
||||
|
Loading…
x
Reference in New Issue
Block a user