Details
-
Improvement
-
Resolution: Unresolved
-
Major
-
None
-
None
-
None
-
None
-
1
Description
Suggested Release Note: NONE
Previously, a ScanTerm could be modified by setting elements of the array returned by `id()`. The MINIMUM_PATTERN and MINIMUM_PATTERN "constants" could be mutated in this way too, either by directly modifying the public static array or by modifying the array returned by `ScanResult.minimum().id()`.
To make ScanTerm fully immutable, the constructor should make a defensive copy of the "id" byte array, and the id() method should also return a copy of the array.
Attachments
Gerrit Reviews
For Gerrit Dashboard: JCBC-2013 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
182346,3 | JCBC-2013 Make ScanTerm immutable | master | couchbase-jvm-clients | Status: MERGED | +2 | +1 |