id,summary,reporter,owner,description,type,status,priority,milestone,component,version,resolution,keywords,cc,blocking,blockedby
2483,jquery dom element construction within frame causing elements to leak,sestizac,,"jQuery Version: 1.2.3
Internet Explorer Version: 6 or 7

In the following example sIEve will report two leaks for every time
leak() is called only when the page is inside a frame.  If this html
is served itself as the main page it will not report a leak BUT if
it's served inside the below frameset these two leaks are reported
each time the leak() function is called:  <div>div<div></div></div>

It does not have anything to do with the append function as
the noleak function (which doens't leak) also uses append.  It happens
anytime you create dom objects using $(""..."").  In my project we are dynamically creating a large table and each node in the table is reported as leaking when leaving the page.  If I remove the frameset these nodes do not leak.

<frameset rows=""*"" framespacing=""0"" border=""false"" frameborder=""0"">
    <frame src=""frame.htm"" frameborder=""0"">
</frameset>

<!-- frame.htm source -->
<html>
        <script language=""javascript"" src=""jquery-1.2.3.min.js""></script>
        <script>
                $(document).ready(function(){
                });

                function leak(){
                        $(""#mydiv"").append("":leak "");
                }

                function noleak(){
                        var text = document.createTextNode(':noleak ');
                        $(""#mydiv"").append(text);
                }
        </script>
        <body >
                <div id=""mydiv"">should be appended here</div><br/>
                <a href=""#"" onclick=""leak();"">leak</a><br/>
                <a href=""#"" onclick=""noleak();"">noleak</a><br/>
        </body>
</html> ",bug,closed,major,,core,1.2.3,worksforme,"leak, leaks, div<div>, frames, framesets",,,
