From 368fdaf51de2478eee9223032b3f7caee58cf132 Mon Sep 17 00:00:00 2001 From: Jeremy White Date: Thu, 29 Dec 2016 14:39:08 -0600 Subject: [PATCH] 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. --- display.js | 1 + 1 file changed, 1 insertion(+) diff --git a/display.js b/display.js index c97f237..68e0af5 100644 --- a/display.js +++ b/display.js @@ -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 &&