Skip to content

panic: runtime error: index out of range [0] with length 0 while converting docx to pdf #505

@knight-ni

Description

@knight-ni

Description

i got error while converting this docx to pdf, can anybody help
测试用户1_测试业务1_centos_DMSERVER20231215.docx

Actual Behavior

panic: runtime error: index out of range [0] with length 0

goroutine 1 [running]:
github.com/unidoc/unioffice/document/convert.(*convertContext).addAbsoluteTable(0xc000180d80, 0xc000961200)
D:/gosdk/pkg/mod/github.com/unidoc/[email protected]/document/convert/convert.go:99 +0x2446
github.com/unidoc/unioffice/document/convert.(*convertContext).addAbsoluteCBCs(0xc000180d80, {0xc000916cd0, 0x1, 0x47e8a7?}, {0xc000916cf8?, 0x1, 0x3cd585?})
D:/gosdk/pkg/mod/github.com/unidoc/[email protected]/document/convert/convert.go:25 +0x7a5
github.com/unidoc/unioffice/document/convert.ConvertToPdfWithOptions(0xc000180480, 0x0)
D:/gosdk/pkg/mod/github.com/unidoc/[email protected]/document/convert/convert.go:155 +0xbe5
github.com/unidoc/unioffice/document/convert.ConvertToPdf(...)
D:/gosdk/pkg/mod/github.com/unidoc/[email protected]/document/convert/convert.go:191
dmHC_Runner/pkg/docx2pdf.WordToPDF({{0xc0002fc28b, 0xd}, {0xc0002fc2aa, 0xd}, {0xc000228000, 0x3c}, {0xc0002fc2ca, 0xe}, 0x16, 0x1474, ...}, ...)
D:/BaiduNetdiskDownload/work/DM/property/mytools/dmHC_Runner/pkg/docx2pdf/docx2pdf.go:29 +0x1f4
main.main()
D:/BaiduNetdiskDownload/work/DM/property/mytools/dmHC_Runner/main.go:90 +0x9f0

Process finished with the exit code 2

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