This commit is contained in:
Pavel Krajcevski 2015-04-11 14:27:34 -07:00
parent acd986d6b7
commit 5c2f4ed272

View file

@ -81,13 +81,13 @@ class Indexer {
case eWrapMode_Wrap: case eWrapMode_Wrap:
{ {
r = i; r = i;
if ((l & (l-1)) == 0) { if ((l & (l-1)) == 0) {
r = (r + l) & (l - 1); r = (r + l) & (l - 1);
} else { } else {
if (r >= l) { r -= l; } if (r >= l) { r -= l; }
if (r < 0) { r += l; } if (r < 0) { r += l; }
} }
} }
break; break;
} }