Erroneous limit-checking code in regionMatches of class String

XMLWordPrintable

    • 1.1
    • sparc
    • solaris_1
    • Not verified

      In both definitions of regionMatches in class String, I believe the line

              int plim = po + other.count;

      should read

              int plim = other.offset + other.count;

      Given that currently String objects do not use nonzero offsets, this error should
      not affect running code in any observable way; but if String should ever be changed
      to use nonzero offset values, then certian calls to regionMatches will behave incorrectly
      by returning false when they should return true.

            Assignee:
            Frank Yellin (Inactive)
            Reporter:
            J. Duke
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: