Completed
Last Updated: 19 Dec 2023 13:50 by ADMIN
Dome
Created on: 14 Oct 2021 11:17
Category: PDFViewer
Type: Bug Report
0
Opening a valid PDF file after trying to open a corrupted PDF file in the PDF Viewer throws a JavaScript error

Bug report

Opening a valid PDF file after trying to open a corrupted PDF file in the PDF Viewer throws a JavaScript error. As a result opening a valid PDF file is not possible.

Uncaught TypeError: Cannot read properties of null (reading 'sendWithStream')
    at PDFPageProxy.streamTextContent (api.js:1114)
    at PDFPageProxy.getTextContent (api.js:1132)
    at init._renderTextLayer (kendo.all.js:170740)
    at init.render (kendo.all.js:170727)
    at kendo.all.js:171384
    at Array.forEach (<anonymous>)
    at r.exec (kendo.all.js:171381)
    at init.execute (kendo.all.js:171959)
    at init.zoom (kendo.all.js:171949)
    at init.fromFile (kendo.all.js:172026)

Reproduction of the problem

  1. Navigate to the PDFViewer Demo
  2. Open a corrupted PDF file, for example CorruptedPdfFile.pdf
  3. Try to open a valid, working PDF file

Screencast

Current behavior

A valid PDF file cannot be opened after a corrupted file was loaded

Expected/desired behavior

It should be possible that a valid PDF file can be opened after a corrupted file has failed to be opened.

Environment

  • Kendo UI version: 2021.3.914
  • Browser: [all]
0 comments