[Bug 40821] Java JRE 8 installer 'jre-8u60-windows-i586.exe' and latter hang during installation

WineHQ Bugzilla wine-bugs at winehq.org
Fri Dec 27 15:43:25 CST 2019


https://bugs.winehq.org/show_bug.cgi?id=40821

Anastasius Focht <focht at gmx.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |focht at gmx.net

--- Comment #19 from Anastasius Focht <focht at gmx.net> ---
Hello folks,

the installer crashes now with stack overflow without showing any user
interface. This is caused by commit
https://source.winehq.org/git/wine.git/commitdiff/64cb9425da43271109bc1df8df4aa32132f257ae
("wininet: Add missing schemes to url_schemes."). It's not a regression as the
Java SE 8 Runtime Environment Update 60+ installer never fully worked.

It requires some amount of work in 'mshtml' and 'jscript' components to make
this installer work. Various improvements have already been done in the past
year(s). Sometimes it looks like the user-visible behaviour gets worse
(regress) - but that's due to hitting different/new code paths, creating more
code coverage in various places.

Previous state, before 64cb9425da432

--- snip ---
...
005e:trace:mshtml:ResProtocolInfo_ParseUrl
04746948)->(L"res://Z/welcome_en.wxl" 7 0 0EC31240 38 0460E04C 0)
...
005e:Ret  urlmon.CoInternetParseUrl() retval=00000000 ret=04729ec6
005e:Call msvcrt.wcschr(0ec3124c L"Z/welcome_en.wxl",0000002f) ret=0472a1c9
...
005e:Call KERNEL32.LoadLibraryExW(0ec3124c L"Z",00000000,00000002) ret=0472a246 
...
005e:Ret  KERNEL32.LoadLibraryExW() retval=00000000 ret=0472a246
...
005e:warn:mshtml:ResProtocol_Start Could not open dll: L"Z"
005e:trace:mshtml:InternetProtocol_Terminate (0EC311D0)->(00000000) 
...
005e:trace:jscript:DispatchEx_Release (043B5FF0) ref=2
005e:trace:jscript:interp_local -1: L"fname"
005e:trace:jscript:interp_str L": xml loading/parsing error - "
005e:trace:jscript:interp_add str(L"res://Z/"...) + str(L": xml loading/parsing
error - ")
005e:trace:jscript:interp_local 1: L"theErr"
005e:trace:jscript:interp_member 
005e:trace:jscript:interp_add str(L"res://Z/"......) + str(L"error")
005e:trace:jscript:interp_call_member 1 0
005e:trace:jscript:invoke_prop_func call L"fatal" 04386108 
...
--- snip ---

It just bailed out earlier. The user interface looks distorted (no page
content, empty buttons) which is expected as various jscript resources are not
fully loaded/processed, event handlers not wired up etc.

Wine 5.0-rc2:

--- snip ---
...
0066:trace:jscript:create_activex_object L"Msxml2.DOMDocument"
0066:trace:jscript:create_activex_object GUID
{f6d90f11-9c73-11d3-b32e-00c04f990bb4}
0066:trace:jscript:AXSite_AddRef (043EBB98) ref=2
0066:trace:jscript:AXSite_Release (043EBB98) ref=1
0066:trace:jscript:interp_pop 2
0066:trace:jscript:DispatchEx_Release (0433A9B8) ref=1 
...
0066:trace:mshtml:ResProtocolInfo_ParseUrl
04B86948)->(L"res://Z:%5Chome%5Cfocht%5CDownloads%5C_unpacked%5Cjre-8u91-windows-i586.exe/welcome_en.wxl"
7 0 04421CD8 106 04A4E04C 0)
...
0066:Ret  urlmon.CoInternetParseUrl() retval=00000000 ret=04b69ec6
0066:Call msvcrt.wcschr(04421ce4
L"Z:\\home\\focht\\Downloads\\_unpacked\\jre-8u91-windows-i586.exe/welcome_en.wxl",0000002f)
ret=04b6a1c9
...
0066:Call KERNEL32.LoadLibraryExW(04421ce4
L"Z:\\home\\focht\\Downloads\\_unpacked\\jre-8u91-windows-i586.exe",00000000,00000002)
ret=04b6a246 
...
0066:Ret  KERNEL32.LoadLibraryExW() retval=00400000 ret=04b6a246 
...
0066:trace:mshtml:ResProtocol_Start trying to find resource type #0017, name
L"welcome_en.wxl" 
...
0066:Call KERNEL32.LoadResource(00400000,035faca8) ret=04b6a334
...
0066:Ret  KERNEL32.LoadResource() retval=03547b28 ret=04b6a334
....
0066:Call urlmon.FindMimeFromData(00000000,04421d5c
L"welcome_en.wxl",04421db8,000003d2,00000000,00000000,04a4e0a4,00000000)
ret=04b6a3b4 
...
0066:trace:mshtml:InternetProtocol_Read (04421BE8)->(04A4D7D0 2048 04A4D7C4) 
...
0066:trace:ole:DispCallFunc retval: 04A4E720 {VT_ERROR: 00000000} 
...
0066:trace:mshtml:DispatchEx_InvokeEx (0442CF28)->(800107d5 800 4 04952F40
00000000 04952F50 00000000)
0066:trace:mshtml:HTMLDOMNode_AddRef (0442CF28) ref=1960
...
0066:trace:mshtml:HTMLElement2_put_accessKey (0442CF28)->(L"I")
...
0066:trace:mshtml:HTMLElement_setAttribute (0442CF28)->(L"accessKey" 04952DA0
{VT_BSTR: L"I"} 00000000)
...
0066:trace:mshtml:DispatchEx_GetDispID (0442CF28)->(L"accessKey" a 04952DBC)
...
0066:Call msvcrt._wcsicmp(0442be74 L"addBehavior",04b85380 L"accessKey")
ret=04a65deb
0066:Ret  msvcrt._wcsicmp() retval=00000001 ret=04a65deb
0066:Call msvcrt._wcsicmp(0442b00c L"accessKey",04b85380 L"accessKey")
ret=04a65deb
0066:Ret  msvcrt._wcsicmp() retval=00000000 ret=04a65deb
0066:trace:mshtml:DispatchEx_InvokeEx (0442CF28)->(800107d5 800 4 04952D30
00000000 04952D40 00000000)
0066:trace:seh:raise_exception code=c00000fd flags=0 addr=0xf7bc0fe9
ip=f7bc0fe9 tid=0066
0066:trace:seh:raise_exception  eax=f7cf7000 ebx=0495256c ecx=00000002
edx=00000002 esi=00000030 edi=f7cf7000
0066:trace:seh:raise_exception  ebp=04952538 esp=04951fd0 cs=0023 ds=002b
es=002b fs=0063 gs=006b flags=00010202
0066:err:seh:setup_exception_record stack overflow 816 bytes in thread 0066 eip
f7bcd6c5 esp 04951000 stack 0x4950000-0x4951000-0x4a50000 
...
--- snip ---

The relevant jscript snippet, extracted from the installer resources for
documentation:

--- snip ---
...
function WixFile (fname) {
    var xmlDoc = require("activex")("Msxml2.DOMDocument");
    // If loading an XML document from a resource, the load must be performed
asynchronously.
    xmlDoc.async = true
    xmlDoc.load(fname)

    // We don't want to process asynchronously because this can cause size
effects
    // like execution of the onload handlers before layout is initialized.
    // So we wait here until the document loading is complete
    // (actually I was not able to reproduce the case when xmlDoc.load returns
before
    // onreadystatechange event is fired, and MSDN example does not check ready
state,
    // but lets do it for safety).
    while (xmlDoc.readyState !== 4) {
        host.delay(10)
    }

    if (xmlDoc.parseError.errorCode != 0) {
        var theErr = xmlDoc.parseError
        log.fatal(fname + ": xml loading/parsing error - " + theErr.reason)
        return
    }

    this.idWithHtml = new Array()

    var strings = xmlDoc.getElementsByTagName("WixLocalization")[0].childNodes

    for (var i = 0; i < strings.length; i++) {
        var element = strings[i]
        this.idWithHtml.push([ element.getAttribute("Id"), element.text ])
    }

    this.iterateStrings = function (callback, thisArg) {
        this.idWithHtml.forEach(function (v) {
            callback.call(thisArg, v[0], v[1])
        })
    }
}
...
    function setAccessKey(element, html) {
        // accessKey is specified by "&" (&) before the letter
        var ampIdx = html.indexOf('&')
        if (ampIdx >= 0 && ampIdx < html.length-1) {
            element.accessKey=html.charAt(ampIdx + 1)
            html = html.substring(0, ampIdx) /*+ "<u>"*/ + html.charAt(ampIdx +
1) /*+ "</u>"*/ + html.substring(ampIdx + 2)
        }
        return html
    }

    this.applyWixFile = function (wixFname) {
        document.getElementById("root").style.display = "none"
        try {
            new WixFile(wixFname).iterateStrings(function (id, html) {
                var element = document.getElementById(id)
                if (element) {
                    html = this.resolveURLs(html, getURLsForId(id))
                    html = setAccessKey(element, html)
                    element.innerHTML = html
                } else if (SPECIAL_IDS.hasOwnProperty(id)) {
                    SPECIAL_IDS[id](html, id)
                } else {
                    log.warning("element[" + id + "] not found")
                }
            }, this)
        } finally {
            document.getElementById("root").style.display = "block"
        }
    }

    this.setLocale = function (loc) {
        var filename = require("Filename")

        var href = window.location.href

        var wixFname = filename.basename(href) + '_' + loc + ".wxl"

        var wixPath = filename.unix.join(filename.dir(href), wixFname)

        this.applyWixFile(wixPath)
    }
...
--- snip ---

'setAccessKey' causes recursion.

Alternative downloads:

http://faucet.aas.duke.edu/pub/pc/bigfix/patches/java/

Internet Archive snapshot:

https://web.archive.org/web/20191227130355/http://faucet.aas.duke.edu/pub/pc/bigfix/patches/java/jre-8u151-windows-i586.exe

$ sha1sum jre-8u*
94f6903ef5514405131298fc351af9467adf945d  jre-8u151-windows-i586.exe
6169b69cbb3c2752e9ae1e878f1bd0e7778b604b  jre-8u91-windows-i586.exe

$ du -sh jre-8u*
61M    jre-8u151-windows-i586.exe
49M    jre-8u91-windows-i586.exe

$ wine --version
wine-5.0-rc2

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.


More information about the wine-bugs mailing list