Fix image name property - forgot to call pdfioStringCreate* APIs for formatted

string...
This commit is contained in:
Michael R Sweet 2024-12-12 07:11:25 -05:00
parent 72e55b5bd1
commit 63cdb13b1b
No known key found for this signature in database
GPG Key ID: BE67C75EC81F3244

View File

@ -334,10 +334,7 @@ new_page(docdata_t *dd) // I - Document data
pdfioPageDictAddFont(page_dict, docfont_names[fontface], dd->fonts[fontface]); pdfioPageDictAddFont(page_dict, docfont_names[fontface], dd->fonts[fontface]);
for (i = 0; i < dd->num_images; i ++) for (i = 0; i < dd->num_images; i ++)
{ pdfioPageDictAddImage(page_dict, pdfioStringCreatef(dd->pdf, "I%u", (unsigned)i), dd->images[i].obj);
snprintf(temp, sizeof(temp), "I%u", (unsigned)i);
pdfioPageDictAddImage(page_dict, temp, dd->images[i].obj);
}
dd->st = pdfioFileCreatePage(dd->pdf, page_dict); dd->st = pdfioFileCreatePage(dd->pdf, page_dict);
dd->color = DOCCOLOR_BLACK; dd->color = DOCCOLOR_BLACK;