|
From: | Nutchanon Wetchasit |
Subject: | [Gnash-commit] [patch #8935] Patch for providing `_global` as a fallback instance in `Function.call()` and `Function.apply()` |
Date: | Tue, 08 Mar 2016 15:16:38 +0000 |
User-agent: | Mozilla/5.0 (X11; Linux i686; rv:25.8) Gecko/20151123 Firefox/31.9 PaleMoon/25.8.1 |
URL: <http://savannah.gnu.org/patch/?8935> Summary: Patch for providing `_global` as a fallback instance in `Function.call()` and `Function.apply()` Project: Gnash - The GNU Flash player Submitted by: nachanon Submitted on: Tue 08 Mar 2016 10:16:37 PM ICT Category: ActionScript Priority: 5 - Normal Status: None Privacy: Public Assigned to: None Originator Email: Open/Closed: Open Discussion Lock: Any _______________________________________________________ Details: Current Gnash's implementation of `Function.call()` and `Function.apply()` have an incorrect behavior when user specified `thisObject` argument as `null` or `undefined`, which it caused the function to be called with `this` instance set to an empty object <https://savannah.gnu.org/bugs/?47354#comment2> rather than the `_global` object. Patch 1 of 2: See the attached `0001_supply-global-instance-fallback-for-function-call-apply.patch`. This patch makes `Function.call()` and `Function.apply()` supply a reference to `Global_as` (a.k.a. ActionScript `_global`) as the context of function call if the `thisObject` argument of the method is specified as `null` or `undefined`; fixing bug #47354. Gnash: 0.8.11dev (patched against git 8b33692 7-Mar-2016) System: Debian GNU/Linux 7.0 Wheezy i386 _______________________________________________________ File Attachments: ------------------------------------------------------- Date: Tue 08 Mar 2016 10:16:37 PM ICT Name: 0001_supply-global-instance-fallback-for-function-call-apply.patch Size: 1kB By: nachanon Patch to use `_global` as function context if called via `Function.call()`/`Function.apply()` with null/undefined instance <http://savannah.gnu.org/patch/download.php?file_id=36570> _______________________________________________________ Reply to this item at: <http://savannah.gnu.org/patch/?8935> _______________________________________________ Message sent via/by Savannah http://savannah.gnu.org/
[Prev in Thread] | Current Thread | [Next in Thread] |