You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@guacamole.apache.org by "James Muehlner (JIRA)" <ji...@apache.org> on 2018/02/07 05:04:00 UTC

[jira] [Commented] (GUACAMOLE-348) Stream download iframe may not exist in DOM at time of removal

    [ https://issues.apache.org/jira/browse/GUACAMOLE-348?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16354969#comment-16354969 ] 

James Muehlner commented on GUACAMOLE-348:
------------------------------------------

Fixed in https://github.com/apache/guacamole-client/pull/249.

> Stream download iframe may not exist in DOM at time of removal
> --------------------------------------------------------------
>
>                 Key: GUACAMOLE-348
>                 URL: https://issues.apache.org/jira/browse/GUACAMOLE-348
>             Project: Guacamole
>          Issue Type: Bug
>          Components: guacamole
>    Affects Versions: 0.9.10-incubating, 0.9.11-incubating, 0.9.12-incubating
>            Reporter: Michael Jumper
>            Assignee: James Muehlner
>            Priority: Major
>
> From GUACAMOLE-327:
> {quote}
> ... IE seems to have a problem with the fallback code for removing the download iframe from the body. If the iframe is successfully removed by the callback of the iframe.onload handler, the stream.onend callback encounters an error because the iframe is no longer attached. A check for iframe's parentElement being defined is a workaround:
> {code:javascript}
> stream.onend = function downloadComplete() {
>             $window.setTimeout(function cleanupIframe() {
>                 if (iframe.parentElement) {
>                     document.body.removeChild(iframe);
>                 }
>             }, DOWNLOAD_CLEANUP_WAIT);
>         };
> {code}
> {quote}
> In both the iframe's onload handler and the stream's onend handler, the iframe itself should only be removed from the DOM if it is actually present.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)