--- a/test/langtools/jdk/javadoc/doclet/lib/JavadocTester.java Thu Oct 19 11:45:23 2017 -0700
+++ b/test/langtools/jdk/javadoc/doclet/lib/JavadocTester.java Thu Oct 19 20:27:47 2017 -0700
@@ -552,7 +552,7 @@
int prevIndex = -1;
for (String s : strings) {
s = s.replace("\n", NL); // normalize new lines
- int currentIndex = fileString.indexOf(s);
+ int currentIndex = fileString.indexOf(s, prevIndex + 1);
checking(s + " at index " + currentIndex);
if (currentIndex == -1) {
failed(s + " not found.");