You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 27, 2024. It is now read-only.
It seems like the SNBT parser is very unreliable. Some inputs cause it to hang, and it returns incorrect data for other inputs.
For example, the perfectly valid SNBT {"a":{}} hangs the SNBT parser until it consumes all available Java heap space and throws an OutOfMemoryError, as in the below code:
InputStreamis = newByteArrayInputStream("{\"a\":{}}".getBytes(StandardCharsets.UTF_8));
try (SNBTIO.StringifiedNBTReaderreader = newSNBTIO.StringifiedNBTReader(is)) {
reader.readNextTag("");
} catch (IOExceptione) {
// Input is a BAIS so this *should* never fail.thrownewAssertionError(e);
}