summaryrefslogtreecommitdiff
path: root/pdf/pdf_annot.c
diff options
context:
space:
mode:
Diffstat (limited to 'pdf/pdf_annot.c')
-rw-r--r--pdf/pdf_annot.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/pdf/pdf_annot.c b/pdf/pdf_annot.c
index 5109ae45..02f91e33 100644
--- a/pdf/pdf_annot.c
+++ b/pdf/pdf_annot.c
@@ -415,16 +415,12 @@ pdf_load_annots(pdf_document *xref, pdf_obj *annots, fz_matrix page_ctm)
annot->next = NULL;
-
- if (annot)
+ if (!head)
+ head = tail = annot;
+ else
{
- if (!head)
- head = tail = annot;
- else
- {
- tail->next = annot;
- tail = annot;
- }
+ tail->next = annot;
+ tail = annot;
}
}
}