[Webkit-unassigned] [Bug 29924] Database Inspector crashes Safari when table has more than 21 columns

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Sep 30 11:32:29 PDT 2009


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


Patrick Mueller <pmuellr at yahoo.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pmuellr at yahoo.com




--- Comment #1 from Patrick Mueller <pmuellr at yahoo.com>  2009-09-30 11:32:29 PDT ---
Here's an example that creates exactly 21 columns which does not appear to hang
Safari when viewing the db in Web Inspector in nightly r48908.  Reloading the
page over and over will result in a new row being added each time.

I wonder if it's some data that's causing a problem?  Why do you think it's the
21st column that causes a problem?

---------- clip here ----------
<script>
var db = openDatabase("bug-29924", "1.0", "sample for webkit bug 29924",
200000);

var cols21def   = "";
var cols21spec  = "";
var vals21spec  = "";
var vals21      = []
for (var i = 1; i <= 21; ++i) {
    cols21def  = cols21def  + "col" + i + " TEXT";
    cols21spec = cols21spec + "col" + i;
    vals21spec = vals21spec + "?";
    vals21.push(new Date().toString());

    if (i != 21) {
        cols21def  += ", ";
        cols21spec += ", ";
        vals21spec += ", ";
    }
}

db.transaction(function(tx) {
    var statement = "CREATE TABLE IF NOT EXISTS TwentyOneColumns (" + cols21def
+ ")";
    tx.executeSql(
        statement, [],  
        function(tx, result) {
            var statement = "INSERT INTO TwentyOneColumns (" + cols21spec + ")
VALUES (" + vals21spec + ")";
            tx.executeSql(
                statement, vals21,  
                function(tx, result) {},
                function(tx, error) {
                    alert("Error during INSERT: " + JSON.stringify(error));
                }
            );
        },
        function(tx, error) {
            alert("Error during CREATE TABLE: " + JSON.stringify(error));
        }
    );
});

</script>
---------- clip here ----------

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



More information about the webkit-unassigned mailing list