pdf-rs/pdf

Example 'names' panics on specific PDF

mwanner opened this issue · 0 comments

I encountered a PDF that yields a panic given a specific PDF. This can currently be triggered with the following two commands:

wget -O/tmp/ug583-ultrascale-pcb-design.pdf \
   "https://www.xilinx.com/content/dam/xilinx/support/documents/user_guides/ug583-ultrascale-pcb-design.pdf"
RUST_BACKTRACE=1 cargo run --example names -- /tmp/ug583-ultrascale-pcb-design.pdf

For me, this currently yields:

thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: UnexpectedPrimitive { expected: "String", found: "Array" }', pdf/examples/names.rs:27:47