Description
This exact Buffer.toString() call prevents parsing XML files that are greater than 0x1fffffe8 characters:
|
xmlData = xmlData.toString(); |
I'm on Node.js v24.13.1, Apple Silicon macOS 26.3.
Input
The .dat file contained within the "RomVault" zip from this release: https://github.com/Eggmansworld/Datfiles/releases/tag/teknoparrot
Code
I don't believe it's consequential, but the options I'm using are:
new XMLParser({
ignoreAttributes: false,
ignoreDeclaration: true,
ignorePiTags: true,
parseTagValue: false,
parseAttributeValue: false,
attributeNamePrefix: '',
}).parse(buffer)
Output
The Buffer.toString() call throws with:
- code:
ERR_STRING_TOO_LONG
- message:
Cannot create a string longer than 0x1fffffe8 characters
expected data
My expectation is that the library can handle Buffers up to the size that the CPU architecture allows.
Would you like to work on this issue?
Bookmark this repository for further updates. Visit SoloThought to know about recent features.
Description
This exact
Buffer.toString()call prevents parsing XML files that are greater than 0x1fffffe8 characters:fast-xml-parser/src/xmlparser/XMLParser.js
Line 21 in fc97a55
I'm on Node.js v24.13.1, Apple Silicon macOS 26.3.
Input
The
.datfile contained within the "RomVault" zip from this release: https://github.com/Eggmansworld/Datfiles/releases/tag/teknoparrotCode
I don't believe it's consequential, but the options I'm using are:
Output
The
Buffer.toString()call throws with:ERR_STRING_TOO_LONGCannot create a string longer than 0x1fffffe8 charactersexpected data
My expectation is that the library can handle Buffers up to the size that the CPU architecture allows.
Would you like to work on this issue?
Bookmark this repository for further updates. Visit SoloThought to know about recent features.