gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] [bug #46131] Gnash's `ExternalInterface.call()` did not c


From: Nutchanon Wetchasit
Subject: [Gnash-commit] [bug #46131] Gnash's `ExternalInterface.call()` did not correctly pass return value from JavaScript function
Date: Wed, 07 Oct 2015 16:28:00 +0000
User-agent: Mozilla/5.0 (X11; Linux i686; rv:25.5) Gecko/20150606 Firefox/31.9 PaleMoon/25.5.0

Follow-up Comment #1, bug #46131 (project gnash):

I have tested around, and this seems to be caused by buffer status check
<http://git.savannah.gnu.org/cgit/gnash.git/tree/libcore/ExternalInterface.cpp?id=f0f66ce7f644a631bbb5f51f78375298fdef3d40#n342>
in
`ExternalInterface::readBrowser()` which is called by
`movie_root::callExternalJavascript()`
<http://git.savannah.gnu.org/cgit/gnash.git/tree/libcore/movie_root.cpp?id=f0f66ce7f644a631bbb5f51f78375298fdef3d40#n1907>
to read the browser-returned value.

The buffer status check caused `ExternalInterface::readBrowser()` to
immediately return an empty string if the browser didn't respond _instantly_.
When this happened, `movie_root::callExternalJavascript()` didn't stick
around
to wait for the return value, it simply passed the empty result back to
`ExternalInterface.call()` implementation, which returned `undefined` value
<http://git.savannah.gnu.org/cgit/gnash.git/tree/libcore/asobj/flash/external/ExternalInterface_as.cpp?id=f0f66ce7f644a631bbb5f51f78375298fdef3d40#n295>
to ActionScript code.

The real return value message that eventually reached Gnash would be caught
by
`movie_root::executeAdvanceCallbacks()`
<http://git.savannah.gnu.org/cgit/gnash.git/tree/libcore/movie_root.cpp?id=f0f66ce7f644a631bbb5f51f78375298fdef3d40#n1555>
as a part of regular frame advancing
routine, then passed to `movie_root::processInvoke()`, and got discarded
<http://git.savannah.gnu.org/cgit/gnash.git/tree/libcore/movie_root.cpp?id=f0f66ce7f644a631bbb5f51f78375298fdef3d40#n1575>.

Gnash: 0.8.11dev (git f0f66ce 23-Sep-2015)
Browser: Iceweasel 10.0.12 (debian)
System: Debian GNU/Linux 7.0 Wheezy i386


    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?46131>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]