We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 34eb633 commit 9e53642Copy full SHA for 9e53642
core/src/main/java/org/jruby/RubyString.java
@@ -360,7 +360,7 @@ private int strLength(ByteList bytes) {
360
}
361
362
private int strLength(ByteList bytes, Encoding enc) {
363
- if (isCodeRangeValid() && enc instanceof UTF8Encoding) return StringSupport.utf8Length(value);
+ if (isCodeRangeValid() && enc instanceof UTF8Encoding) return StringSupport.utf8Length(bytes);
364
365
long lencr = strLengthWithCodeRange(bytes, enc);
366
int cr = unpackArg(lencr);
0 commit comments