Disable the onload function when clearing the image source.

This fixes a bug introduced by my commit 42134d3e, which would
lead to an infinite recursion of onload statements.
This commit is contained in:
Jeremy White 2016-12-29 14:39:08 -06:00
parent d83dc14e15
commit 368fdaf51d
1 changed files with 1 additions and 0 deletions

View File

@ -933,6 +933,7 @@ function handle_draw_jpeg_onload()
// Give the Garbage collector a clue to recycle this; avoids
// fairly massive memory leaks during video playback
this.onload = undefined;
this.src = EMPTY_GIF_IMAGE;
if (this.o.descriptor &&