don't match yourkit thread name twice (IDEA-CR-21711)

This commit is contained in:
peter
2017-06-09 17:16:40 +02:00
parent 732719f619
commit c7d35311b2
@@ -204,9 +204,8 @@ public class ThreadDumpParser {
line = StringUtil.replace(line, " [DAEMON]", "");
}
m = ourYourkitThreadStartPattern.matcher(line);
if (!m.matches()) m = ourYourkitThreadStartPattern2.matcher(line);
if (m.matches()) {
m = matchYourKit(line);
if (m != null) {
ThreadState state = new ThreadState(m.group(1), m.group(2));
state.setDaemon(daemon);
return state;
@@ -214,6 +213,17 @@ public class ThreadDumpParser {
return null;
}
@Nullable
private static Matcher matchYourKit(String line) {
Matcher m = ourYourkitThreadStartPattern.matcher(line);
if (m.matches()) return m;
m = ourYourkitThreadStartPattern2.matcher(line);
if (m.matches()) return m;
return null;
}
private static boolean tryParseThreadState(final String line, final ThreadState threadState) {
Matcher m = ourThreadStatePattern.matcher(line);
if (m.find()) {