diff options
author | Chris Liddell <chris.liddell@artifex.com> | 2022-02-01 08:37:11 +0000 |
---|---|---|
committer | Chris Liddell <chris.liddell@artifex.com> | 2022-02-01 08:38:53 +0000 |
commit | 3c75a977879b066c20f6c9587481ac93e476630b (patch) | |
tree | a8dc66de759483328b1eef72744471977ba7085f | |
parent | 5db3e3fa6a3671fc95ebcf40b245a2f213cd9d6f (diff) | |
download | ghostpdl-3c75a977879b066c20f6c9587481ac93e476630b.tar.gz |
oss-fuzz 44264: pdfi_pscript_interpret() check input buffer limit
Add a missing check for an exhausted buffer
-rw-r--r-- | pdf/pdf_fontps.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/pdf/pdf_fontps.c b/pdf/pdf_fontps.c index ffff236ac..02384ab24 100644 --- a/pdf/pdf_fontps.c +++ b/pdf/pdf_fontps.c @@ -178,7 +178,7 @@ pdfi_pscript_interpret(pdf_ps_ctx_t *cs, byte *pdfpsbuf, int64_t buflen) *pdfpsbuf != char_CR) pdfpsbuf++; - if (*pdfpsbuf == char_EOL) + if (pdfpsbuf < buflim && *pdfpsbuf == char_EOL) pdfpsbuf++; } break; |