Skip to content

Commit

Permalink
Fix image name property - forgot to call pdfioStringCreate* APIs for …
Browse files Browse the repository at this point in the history
…formatted

string...
  • Loading branch information
michaelrsweet committed Dec 12, 2024
1 parent 72e55b5 commit 63cdb13
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions examples/md2pdf.c
Original file line number Diff line number Diff line change
Expand Up @@ -334,10 +334,7 @@ new_page(docdata_t *dd) // I - Document data
pdfioPageDictAddFont(page_dict, docfont_names[fontface], dd->fonts[fontface]);

for (i = 0; i < dd->num_images; i ++)
{
snprintf(temp, sizeof(temp), "I%u", (unsigned)i);
pdfioPageDictAddImage(page_dict, temp, dd->images[i].obj);
}
pdfioPageDictAddImage(page_dict, pdfioStringCreatef(dd->pdf, "I%u", (unsigned)i), dd->images[i].obj);

dd->st = pdfioFileCreatePage(dd->pdf, page_dict);
dd->color = DOCCOLOR_BLACK;
Expand Down

0 comments on commit 63cdb13

Please sign in to comment.