[Webkit-unassigned] [Bug 24194] New: XHR request empty in inspector

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Feb 26 03:03:23 PST 2009


https://bugs.webkit.org/show_bug.cgi?id=24194

           Summary: XHR request empty in inspector
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: Macintosh
               URL: http://rene.lico.nl/safari.php
        OS/Version: Mac OS X 10.5
            Status: UNCONFIRMED
          Severity: Minor
          Priority: P5
         Component: Web Inspector
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: rene at lico.nl


When a resource is clicked _before_ it finished loading, the body stays empty.

Steps to reproduce bug

- Open example script (source below): http://rene.lico.nl/safari.php
- Open inspector
- Click "Resources"
- Click last resource "safari.php"e; (resource should be loading while you
click on it)
- Wait for the resource to load ("Response headers" appear)
- The body is empty
- Wait for another resource to load
- Click the loaded resource (note: this should not be the resource you've
clicked at step 3)
- The body contains "-- test --"

Comments

- If you don't wait for a resource to complete before you open it in the
inspector, the body stays empty.
- The body should contain "-- test --"
- The XHR is delayed by 5 seconds and looped until infinity.
- Only tested in "Version 4 Public Beta (5528.16)" and "Version 4 Public Beta
(5528.16, r41242) on "Mac OS X 10.5.6, intel c2d 2 ghz"

Source

<?
        if (array_key_exists("test",$_GET)) {
                sleep(5);
                die("-- test --");
        }
?>
<html>
        <head>
                <title>Webkit XHR test</title>
                <script type="text/javascript" charset="utf-8">
                        function init_test () {
                                loadXMLDoc()
                        }

                        var req;

                        function loadXMLDoc() {
                                req = new XMLHttpRequest();
                                req.onreadystatechange = processReqChange;
                                req.open("GET",
'<?=$_SERVER["PHP_SELF"]?>?test=1', true);
                                req.send("");
                        }       

                        function processReqChange() {
                                if (req.readyState == 4 && req.status == 200) {
                                        loadXMLDoc();
                                }
                        }               
                </script>
        </head>
        <body onload="init_test();">
                <h1>Bug: XHR request empty in inspector</h1>

                <h2>Steps to reproduce bug</h2>
                <ol>
                        <li>Open inspector</li>
                        <li>Click "Resources"</li>
                        <li>Click last resource "safari.php"e;
(resource should be loading while you click on it)</li>
                        <li>Wait for the resource to load ("Response
headers" appear)</li>
                        <li style="color: red;">The body is empty</li>
                        <li>Wait for another resource to load</li>
                        <li>Click the loaded resource (note: this should not be
the resource you've clicked at step 3)</li>
                        <li style="color: green;">The body contains "--
test --"</li>
                </ol>

                <h2>Comments</h2>
                <ul>
                        <li>If you don't wait for a resource to complete before
you open it in the inspector, the body stays empty.</li>
                        <li>The body should contain "-- test --"</li>
                        <li>The XHR is delayed by 5 seconds and looped until
infinity.</li>
                </ul>
        </body>
</html>


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list