Skip to content

libyang coredump when parsing module #2013

@lyzliyuzhi91

Description

@lyzliyuzhi91

ietf-netconf.zip

When using yanglint:
[root@my /data/opensource/libyang2-datacom/build]$./yanglint
YANGLINT[W]: No saved history.

add /data/yang-repo-sdk-only-netconf/ietf-netconf.yang
Segmentation fault (core dumped)

stack:
#0 0x0000ffff86fa6394 in lys_compile_extension (ctx=0xffffcf5e0e88, extp=0x2ccfd7c8, ext=0x2cd080c8)
at /data/opensource/libyang2-datacom/src/schema_compile.c:124
#1 0x0000ffff86fa69f8 in lys_compile_ext (ctx=0xffffcf5e0e88, extp=0x2ccfd7c8, ext=0x2cd080c8, parent=0x2cd06be0)
at /data/opensource/libyang2-datacom/src/schema_compile.c:172
#2 0x0000ffff86fac3fc in lys_compile (mod=0x2ccef700, unres=0x2cccd498) at /data/opensource/libyang2-datacom/src/schema_compile.c:1594
#3 0x0000ffff86fab560 in lys_compile_depset_r (ctx=0x2cccd400, dep_set=0x2cd06980, unres=0x2cccd468)
at /data/opensource/libyang2-datacom/src/schema_compile.c:1386
#4 0x0000ffff86fab764 in lys_compile_depset_all (ctx=0x2cccd400, unres=0x2cccd468) at /data/opensource/libyang2-datacom/src/schema_compile.c:1445
#5 0x0000ffff86fd7118 in lys_parse (ctx=0x2cccd400, in=0x2ccda4c0, format=LYS_IN_YANG, features=0xffffcf5e20b8, module=0x0)
at /data/opensource/libyang2-datacom/src/tree_schema.c:1925
#6 0x0000000000406d34 in cmd_add (ctx=0x430fa8 , cmdline=0x2ccdce20 "add /data/yang-repo-sdk-only-netconf/ietf-netconf.yang ")
at /data/opensource/libyang2-datacom/tools/lint/cmd_add.c:160
#7 0x000000000040b794 in main (argc=1, argv=0xffffcf5e22f8) at /data/opensource/libyang2-datacom/tools/lint/main.c:84

version:
2.1.30

thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    is:bugBug description.status:completedFrom the developer perspective, the issue was solved (bug fixed, question answered,...)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions