Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-85736

WASM: Cannot load when deployed on https web server

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P2: Important
    • Resolution: Duplicate
    • Affects Version/s: 5.14.2
    • Fix Version/s: None
    • Component/s: Network
    • Labels:
      None
    • Platform/s:
      WebAssembly

      Description

      When I deployed the wasm program on the http web server, everything worked fine. But when I deployed the SSL certificate to upgrade to the https server, the wasm program could not be loaded normally and an error was reported

      Application exit (TypeError: undefined is not an object (evaluating'handle[name]'))

      I thought it was my deployment problem, but I opened the official Qt example and still reported an error. (Except for Slate Demo).
      The screenshot has been uploaded.

       

      According to the content of the error, I look the js file. The code that went wrong is as follows:

      functionBody+="    var rv = handle[name]("+argsList+");\n"

      There is no undefined judgment on the handle value. Through simple modification, it is changed to:

      functionBody+="    if(handle){var rv = handle[name]("+argsList+");}\n"

      The https program is back to normal.

       

      There is no such undefined judgment in the js file of Slate Demo, but it works normally, so the problem is in elsewhere, but I cannot locate the specific problem.

        Attachments

          Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            Activity

              People

              Assignee:
              lpotter Lorn Potter
              Reporter:
              jasonwong Jason Wong
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes