Skip to content

"Memory allocation failed" error for truncated xml/html input on recent libxml2 versions #456

Open
@arnejohannesholmin

Description

@arnejohannesholmin

In xml2 v1.3.6 the following commands worked on macOS, Linux and Windows (notice the missing ">" at the end of the string):

tmpText <- "<?xml version=\"1.0\" encoding=\"utf-8\"?><Biotic xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-ins\""
res <- read_html(tmpText)

In xml2 v1.3.7 and v1.3.8 I get the following error on Windows:

"Memory allocation failed"

When completing the block by ">", I do not get the error:

tmpText <- "<?xml version=\"1.0\" encoding=\"utf-8\"?><Biotic xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-ins\">"
res <- read_html(tmpText)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions