mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-10 18:25:37 +02:00
Merge pull request #7102 from brendandahl/onerror
Log uncaught global errors.
This commit is contained in:
commit
bec4891f5d
1 changed files with 4 additions and 1 deletions
|
@ -281,7 +281,10 @@ var Driver = (function DriverClosure() {
|
||||||
|
|
||||||
run: function Driver_run() {
|
run: function Driver_run() {
|
||||||
var self = this;
|
var self = this;
|
||||||
|
window.onerror = function(message, source, line, column, error) {
|
||||||
|
self._info('Error: ' + message + ' Script: ' + source + ' Line: ' +
|
||||||
|
line + ' Column: ' + column + ' StackTrace: ' + error);
|
||||||
|
};
|
||||||
this._info('User agent: ' + navigator.userAgent);
|
this._info('User agent: ' + navigator.userAgent);
|
||||||
this._log('Harness thinks this browser is "' + this.browser +
|
this._log('Harness thinks this browser is "' + this.browser +
|
||||||
'" with path "' + this.appPath + '"\n');
|
'" with path "' + this.appPath + '"\n');
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue