Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -420,6 +420,9 @@ public Block getRegion(int positionOffset, int length)
public Block copyRegion(int position, int length)
{
checkValidRegion(positionCount, position, length);
if (length == 0) {
Comment thread
sopel39 marked this conversation as resolved.
Outdated
return dictionary.copyRegion(0, 0);
}
// Avoid repeated volatile reads to the uniqueIds field
int uniqueIds = this.uniqueIds;
if (length <= 1 || (uniqueIds == dictionary.getPositionCount() && isSequentialIds)) {
Expand Down