|
From: | Nutchanon Wetchasit |
Subject: | [Gnash-commit] [patch #8853] Patch to allow calling zero-argument JavaScript function via `ExternalInterface.call()` |
Date: | Tue, 12 Jan 2016 16:38:06 +0000 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:25.5) Gecko/20150606 Firefox/31.9 PaleMoon/25.5.0 |
URL: <http://savannah.gnu.org/patch/?8853> Summary: Patch to allow calling zero-argument JavaScript function via `ExternalInterface.call()` Project: Gnash - The GNU Flash player Submitted by: nachanon Submitted on: Tue 12 Jan 2016 11:38:05 PM ICT Category: core Priority: 5 - Normal Status: None Privacy: Public Assigned to: None Originator Email: Open/Closed: Open Discussion Lock: Any _______________________________________________________ Details: Current Gnash's `ExternalInterface.call()` does not allow calling JavaScript function with no argument. If one tries to do it, the method will just return `undefined` and JavaScript call will not be made <https://savannah.gnu.org/bugs/?46878#comment1>. This is caused by an incorrect argument check <http://git.savannah.gnu.org/cgit/gnash.git/tree/libcore/asobj/flash/external/ExternalInterface_as.cpp?id=6671ff0f7c0c9d35d4432001a64f2c132f70158f#n289> in `ExternalInterface.call()` implementation which mistakenly rejects its invocation when number of argument is less than 2. (It should reject only when number of argument is *less than 1* which would be when the required `functionName` argument was not given) Patch 1 of 2: See the attached `0001_allow-single-argument-externalinterface-call.patch`. This patch corrects the comparison used in argument check, allowing zero-argument JavaScript function call to be made; fixing bug #46878. Automated test will follow. Gnash: 0.8.11dev (patched against git 6671ff0 12-Jan-2016) Browser: Iceweasel 10.0.12 (debian) System: Debian GNU/Linux 7.0 Wheezy i386 _______________________________________________________ File Attachments: ------------------------------------------------------- Date: Tue 12 Jan 2016 11:38:05 PM ICT Name: 0001_allow-single-argument-externalinterface-call.patch Size: 763B By: nachanon Patch for allowing single-argument `ExternalInterface.call()` invocation <http://savannah.gnu.org/patch/download.php?file_id=36002> _______________________________________________________ Reply to this item at: <http://savannah.gnu.org/patch/?8853> _______________________________________________ Message sent via/by Savannah http://savannah.gnu.org/
[Prev in Thread] | Current Thread | [Next in Thread] |