From 5a390d0ce33a7dd9400675a236424db390a807c5 Mon Sep 17 00:00:00 2001 From: Robin Watts Date: Mon, 22 Feb 2016 15:44:06 +0000 Subject: Fix flaw in printing objects. When printing a PDF object to a file, if it was a name, then we'd output without a required \n. For example: 10 0 obj /SomeNameOrOtherendobj This would trip gs up. --- source/pdf/pdf-write.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source/pdf') diff --git a/source/pdf/pdf-write.c b/source/pdf/pdf-write.c index 86e4ebaf..0dacdcf8 100644 --- a/source/pdf/pdf-write.c +++ b/source/pdf/pdf-write.c @@ -1792,7 +1792,7 @@ static void writeobject(fz_context *ctx, pdf_document *doc, pdf_write_state *opt { fz_printf(ctx, opts->out, "%d %d obj\n", num, gen); pdf_print_obj(ctx, opts->out, obj, opts->do_tight); - fz_puts(ctx, opts->out, "endobj\n\n"); + fz_puts(ctx, opts->out, "\nendobj\n\n"); } else if (entry->stm_ofs < 0 && entry->stm_buf == NULL) { -- cgit v1.2.3