8263044: jdk/jfr/jvm/TestDumpOnCrash.java timed out

Reviewed-by: mgronlun
This commit is contained in:
Erik Gahlin 2022-10-12 11:42:47 +00:00
parent bdb4ed0fb1
commit 94ec729faa

View File

@ -164,8 +164,18 @@ public final class ChunkHeader {
Logger.log(LogTag.JFR_SYSTEM_PARSER, LogLevel.INFO, "Chunk: finalChunk=" + finalChunk); Logger.log(LogTag.JFR_SYSTEM_PARSER, LogLevel.INFO, "Chunk: finalChunk=" + finalChunk);
absoluteChunkEnd = absoluteChunkStart + chunkSize; absoluteChunkEnd = absoluteChunkStart + chunkSize;
return; return;
} else if (finished) { } else {
throw new IOException("No metadata event found in finished chunk."); if (finished) {
throw new IOException("No metadata event found in finished chunk.");
}
if (chunkSize == HEADER_SIZE) {
// This ensures that a non-streaming parser is able
// to break out of the loop in case the file is
// ended before the first metadata event has
// been written. This can happen during a failed crash
// dump.
input.pollWait();
}
} }
} }
} }