From b2cdd558590c942150838d99c7429ec9a43329ce Mon Sep 17 00:00:00 2001 From: samhed Date: Fri, 10 Jun 2016 17:15:42 +0200 Subject: [PATCH] Proper error handling for tight filters Don't throw an exception when we encounter an unsupported tight subencoding. --- include/rfb.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/include/rfb.js b/include/rfb.js index c022969b..d0e6c8f7 100644 --- a/include/rfb.js +++ b/include/rfb.js @@ -2011,8 +2011,7 @@ var RFB; } else { // Filter 0, Copy could be valid here, but servers don't send it as an explicit filter // Filter 2, Gradient is valid but not use if jpeg is enabled - // TODO(directxman12): why aren't we just calling '_fail' here - throw new Error("Unsupported tight subencoding received, filter: " + filterId); + this._fail("Unsupported tight subencoding received, filter: " + filterId); } break; case "copy":