[rfc][icedtea-web] Make 'getvalue' nonblocking to reduce hanging chance & improve responsivity
adomurad at redhat.com
Fri Jun 7 11:11:55 PDT 2013
Hi all. I am very happy to present this patch!
All Firefox hanging bugs had a common theme, Firefox waits for the
result of some function to finish from the plugin, and IcedTea-Web
plugin-side waits as well for the java-side.
This patch should reduce the chance of Firefox outright hanging, by
making the most frequent site of these occurences nonblocking. This will
also improve responsivity, eg Firefox no longer 'hangs' while waiting
for you to accept or deny a confirmation message.
The patch delays waiting for initialization of the applet until its
absolutely needed - which is only when the applet is communicated with
This especially benefits the majority of applets that do not use
liveconnect. Eg the applets at
http://www.walter-fendt.de/ph14e/resultant.htm no longer presents a
blank page for a while, for me.
The patch introduces (with tests) a helper class, NPObjectRef. This was
done to make this patch easier to reason about. It should be far easier
to know now when to retain/release an object (almost always automatic,
only call raw_retain() when returning raw NPObject* to browser).
It also introduces a wrapper around g_strdup_printf with a (very) simple
I have done testing on the patch and it looks OK, but I will still test
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 36196 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20130607/a6d49022/Non-blocking-npapi-getvalue.patch
More information about the distro-pkg-dev