diff options
Diffstat (limited to 'source/pdf/pdf-xref.c')
-rw-r--r-- | source/pdf/pdf-xref.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/pdf/pdf-xref.c b/source/pdf/pdf-xref.c index 43fd3ea4..6db54472 100644 --- a/source/pdf/pdf-xref.c +++ b/source/pdf/pdf-xref.c @@ -139,7 +139,7 @@ pdf_obj *pdf_trailer(fz_context *ctx, pdf_document *doc) /* Return the document's final trailer */ pdf_xref *xref = &doc->xref_sections[0]; - return xref->trailer; + return xref ? xref->trailer : NULL; } void pdf_set_populating_xref_trailer(fz_context *ctx, pdf_document *doc, pdf_obj *trailer) |