Product: PDFNet Java Library, CADModule
Product Version: 12.2.0
Please give a brief summary of your issue:
When converting .dwg files containing XRefs, the conversion fails with an Exception.
Please describe your issue and provide steps to reproduce it:
This is on Linux. See the attached sample files below.
master.dwg (16.0 KB)
rectangle.dwg (13.4 KB)
circle.dwg (16.9 KB)
rectangle.dwg contains a small rectangle, circle.dwg contains a circle. master.dwg has some lines and refers to rectangle and circle. When all three are present in the same folder, the CADModule is capable of finding the referenced files and created a PDF from master with the references resolved and the output visible. This has worked until we upgraded to PDFNet library and CADModule 12.2.0.
We now get the following error:
2026-10-14 09:21:53.188 Caused by: Exception:
2026-10-14 09:21:53.188 Message: Exception:
2026-10-14 09:21:53.188 Message: Error converting CAD content using CAD2PDF module Add-On.
2026-10-14 09:21:53.188 Exit code: 0X25
2026-10-14 09:21:53.188 Failed to create valid PDF: PDF header not found. The file is not a valid PDF document.
2026-10-14 09:21:53.188 Parser.cpp:1494
2026-10-14 09:21:53.188 SkipHeader
2026-10-14 09:21:53.188 2026-10-14 09:21:53.188 Conditional expression: exit_code == 0
2026-10-14 09:21:53.188 Version : 12.2.0-4345c0e
2026-10-14 09:21:53.188 Platform : Linux
2026-10-14 09:21:53.188 Architecture : AMD64
2026-10-14 09:21:53.188 Filename : Cad2Pdf.cpp
2026-10-14 09:21:53.188 Function : Convert
2026-10-14 09:21:53.188 Linenumber : 976
2026-10-14 09:21:53.188 2026-10-14 09:21:53.188 Conditional expression: exit_code == 0
2026-10-14 09:21:53.188 Filename : Cad2Pdf.cpp
2026-10-14 09:21:53.188 Function : Convert
2026-10-14 09:21:53.188 Linenumber : 976
2026-10-14 09:21:53.188 Error code : 0
2026-10-14 09:21:53.188 2026-10-14 09:21:53.188 at com.pdftron.pdf.Convert.FromCAD(Native Method) ~[PDFNet-12.2.0.jar:na]
2026-10-14 09:21:53.188 at com.pdftron.pdf.Convert.fromCAD(Convert.java:4191) ~[PDFNet-12.2.0.jar:na]
2026-10-14 09:21:53.188 at com.chapoo.pdftronconverter.conversion.service.imp.PdftronConversionServiceImp.getPdfDocFromCAD(PdftronConversionServiceImp.java:104) ~[classes/:na]
2026-10-14 09:21:53.188 at com.c.pdftronconverter.conversion.service.imp.PdftronConversionServiceImp.convertToOptimizedPdf(PdftronConversionServiceImp.java:69) ~[classes/:na]
2026-10-14 09:21:53.188 … 61 common frames omitted
This looks like a regression, as this has worked well until the new release.