diff options
author | Sebastian Rasmussen <sebras@gmail.com> | 2012-06-22 01:29:17 +0200 |
---|---|---|
committer | Tor Andersson <tor.andersson@artifex.com> | 2012-06-25 13:50:12 +0200 |
commit | 767b08e66fef57327b9a2af023207b97300d42e2 (patch) | |
tree | 18a5cfd3ff51125be3881bc19b28e8da8650fdbc /pdf/pdf_annot.c | |
parent | 0772da1a2ca814919428a8eca995b2d776eff41f (diff) | |
download | mupdf-767b08e66fef57327b9a2af023207b97300d42e2.tar.xz |
Warning fixes and various clean ups:
Remove unused variable, silencing compiler warning.
No need to initialize variables twice.
Remove initialization of unread variable.
Remove unnecessary check for NULL.
Close output file upon error in cmapdump.
Diffstat (limited to 'pdf/pdf_annot.c')
-rw-r--r-- | pdf/pdf_annot.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/pdf/pdf_annot.c b/pdf/pdf_annot.c index 3864c62e..f6c70f90 100644 --- a/pdf/pdf_annot.c +++ b/pdf/pdf_annot.c @@ -399,15 +399,12 @@ pdf_load_annots(pdf_document *xref, pdf_obj *annots) pdf_transform_annot(annot); - if (annot) + if (!head) + head = tail = annot; + else { - if (!head) - head = tail = annot; - else - { - tail->next = annot; - tail = annot; - } + tail->next = annot; + tail = annot; } } } |