diff options
author | Tor Andersson <tor.andersson@artifex.com> | 2012-02-03 16:48:47 +0100 |
---|---|---|
committer | Tor Andersson <tor.andersson@artifex.com> | 2012-02-03 16:48:47 +0100 |
commit | e1016a6c646b3b92f23bea1f0aa959f0ae0b3359 (patch) | |
tree | ce1861fa120ea5a589bc97c91791d34c8d042e88 | |
parent | f262a8c0bfae0cd90c2cd29acd409baf2157c241 (diff) | |
download | mupdf-e1016a6c646b3b92f23bea1f0aa959f0ae0b3359.tar.xz |
Fix NULL dereference when freeing fz_link objects.
-rw-r--r-- | fitz/doc_link.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fitz/doc_link.c b/fitz/doc_link.c index c9065f24..71f5dfbf 100644 --- a/fitz/doc_link.c +++ b/fitz/doc_link.c @@ -55,7 +55,7 @@ fz_keep_link(fz_context *ctx, fz_link *link) void fz_drop_link(fz_context *ctx, fz_link *link) { - if (--link->refs == 0) + if (link && --link->refs == 0) { fz_drop_link(ctx, link->next); fz_free_link_dest(ctx, &link->dest); |