diff options
author | Tor Andersson <tor.andersson@artifex.com> | 2016-10-12 12:18:18 +0200 |
---|---|---|
committer | Tor Andersson <tor.andersson@artifex.com> | 2016-10-12 14:45:42 +0200 |
commit | 0bb6e0b11cf2fda4ecdb89a6407d919c6ed328f5 (patch) | |
tree | 9eda479951c3dbe2ee0cd2ea9417e3a4a829044d /source/fitz/font.c | |
parent | ca8d9898719671627231c9d909cfd9ba252ab4a2 (diff) | |
download | mupdf-0bb6e0b11cf2fda4ecdb89a6407d919c6ed328f5.tar.xz |
Remove superfluous context null checks.
Code MUST pass a non-null context to all functions.
Checking ctx for null and failing silently is no more useful
than segfaulting.
fz_keep_imp and fz_drop_imp handle NULL pointers safely, so
the NULL checks for this can also be dropped at the same time.
Diffstat (limited to 'source/fitz/font.c')
-rw-r--r-- | source/fitz/font.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/fitz/font.c b/source/fitz/font.c index 6d86133c..88d5e358 100644 --- a/source/fitz/font.c +++ b/source/fitz/font.c @@ -110,7 +110,7 @@ free_resources(fz_context *ctx, fz_font *font) void fz_decouple_type3_font(fz_context *ctx, fz_font *font, void *t3doc) { - if (!ctx || !font || !t3doc || font->t3doc == NULL) + if (!font || !t3doc || font->t3doc == NULL) return; if (font->t3doc != t3doc) |