Force the spool file to be in raw format.
void pdfPrintRawSpoolFile(PDFHandle pdf, int raw)
If this function is called with raw = 1, XpdfPrint forces spool files to be in raw format. If called with raw = 0, the driver's default spool file format - which may be raw, EMF, or something else, depending on the driver - will be used.

pdfPrintResetParams resets this to its default value of 1.

Changing this to zero is usually a bad idea, unless your application specifically requires it.

pdfPrintRawSpoolFile(pdf, 0);