Patching CanvasRenderingContext2D.prototype.drawImage

See https://github.com/mozilla/pdf.js/issues/4436 for details