Skip to content

nil pointer dereference at parse.go:145 #75

Closed
@hokumski

Description

@hokumski

Hi!

There's possible "nil pointer dereference" error at line 145 of parse.go, p.prev could be nil

AddSibling(p.prev.Parent, node)

(I have XML file causing this error)

Activity

zhengchun

zhengchun commented on Dec 8, 2021

@zhengchun
Contributor

@hokumski , Please provide your XML file.

hokumski

hokumski commented on Dec 9, 2021

@hokumski
Author

v1.3.8

parsed, err := xmlquery.Parse(strings.NewReader(string(xmlDataBytes)))

publication-6430.xml.zip

zhengchun

zhengchun commented on Dec 10, 2021

@zhengchun
Contributor

v1.3.9 to fix

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @hokumski@zhengchun

        Issue actions

          nil pointer dereference at parse.go:145 · Issue #75 · antchfx/xmlquery