<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>13815</bug_id>
          
          <creation_ts>2007-05-22 10:01:10 -0700</creation_ts>
          <short_desc>bad parsing of JavaScript code from big and complex external .js</short_desc>
          <delta_ts>2011-08-12 13:10:41 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>JavaScriptCore</component>
          <version>523.x (Safari 3)</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.4</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>INVALID</resolution>
          
          
          <bug_file_loc>http://www.formfaces.com/faces/Examples/Bookstore/index.html</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          <dependson>4045</dependson>
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Luigi Giannini">luigi.giannini</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>barraclough</cc>
    
    <cc>ddkilzer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>9445</commentid>
    <comment_count>0</comment_count>
    <who name="Luigi Giannini">luigi.giannini</who>
    <bug_when>2007-05-22 10:01:10 -0700</bug_when>
    <thetext>FormFaces is a ZERO server-side processing and ZERO plug-ins XForm implementation in pure  JavaScript. FormFaces is freely licensed under the BSD.
While WebKit has not support for XForm directly or via a plug-in (may be in a far long time distance?) this is the only way to work with XFrom on WebKit based browser.
The URL above is for access a demo of a bookstore full XForm based that work on Firefox 2.x on Mac and Win and IE 6.x and 7 on Win.
On that site there&apos;s a full suite (32) for test at this URL: http://www.formfaces.com/faces/Examples/Test%20Pages/index.html
I have spent time to run every test on WebKit 522+: all pass except these:
http://www.formfaces.com/faces/Examples/Test%20Pages/itemset.html
http://www.formfaces.com/faces/Examples/Test%20Pages/submit.html
http://www.formfaces.com/faces/Examples/Test%20Pages/replace-all.html

These tests all pass on FireFox 2.x on Mac and Opera 9.21 on Mac while on WebKit 522+ return Syntax Error.
Then this is a bug relative to parsing Javascript from external .js ???
(I try to read the external .js that implement XForm but is very hard because is a one line code of 96Kbyte)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>9449</commentid>
    <comment_count>1</comment_count>
    <who name="David Kilzer (:ddkilzer)">ddkilzer</who>
    <bug_when>2007-05-22 10:15:08 -0700</bug_when>
    <thetext>(In reply to comment #0)
&gt; http://www.formfaces.com/faces/Examples/Test%20Pages/itemset.html
&gt; http://www.formfaces.com/faces/Examples/Test%20Pages/submit.html
&gt; http://www.formfaces.com/faces/Examples/Test%20Pages/replace-all.html

Every one of these tests ends with an alert sheet which says (among other things):

&quot;Maximum call stack size exceeded.&quot;

Related to Bug 4045?

Confirmed with a local debug build of WebKit r21639 with Safari 2.0.4 (419.3) on Mac OS X 10.4.9 (8P135).

</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>8835</commentid>
    <comment_count>2</comment_count>
    <who name="Luigi Giannini">luigi.giannini</who>
    <bug_when>2007-05-29 03:25:18 -0700</bug_when>
    <thetext>Thanks David for your fast reply.
Today I can respond to Your last question: &quot;Related to Bug 4045?&quot;: Yes it is related but not duplicated.
After dowload the latest nightly build of webkit I change the source code of JavaScriptCore/kjs/object.cpp according to the naive fix shown in Bug 4045. (I only comment the code that change JavaScript call stack in accordance with platform leaving always KJS_MAX_STACK 1000 !) and the error alert sheets that report: &quot;Maximum call stack size exceeded&quot; are disappeared.
Two of test now pass:
http://www.formfaces.com/faces/Examples/Test%20Pages/itemset.html
http://www.formfaces.com/faces/Examples/Test%20Pages/submit.html
But the third no. Now it&apos;s stopped by this error: &quot;NO_MODIFICATION_ALLOWED_ERR: DOM Exception 7&quot;

OK is a step ahead but I wonder of these things:
Why would the WebKit has a different behavior on different platform?
Why isn&apos;t the bug 4045 fixed if there is a fix? Too simple to pass in the main tree code?

Now is sure that bug 4045 blocks two others bugs: 6628 and 13815.
Please fix asap ...

Thanks</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1832</commentid>
    <comment_count>3</comment_count>
    <who name="David Kilzer (:ddkilzer)">ddkilzer</who>
    <bug_when>2007-08-20 21:30:34 -0700</bug_when>
    <thetext>(In reply to comment #1)
&gt; (In reply to comment #0)
&gt; &gt; http://www.formfaces.com/faces/Examples/Test%20Pages/itemset.html
&gt; &gt; http://www.formfaces.com/faces/Examples/Test%20Pages/submit.html

These are now fixed after fixing Bug 4045!

&gt; &gt; http://www.formfaces.com/faces/Examples/Test%20Pages/replace-all.html

This page now fails with the following alert() dialog:

&gt; An error has occurred!
&gt; 
&gt; Error: NO_MODIFICATION_ALLOWED_ERR: DOM Exception 7
&gt; 
&gt; Stack trace:
&gt; (stack trace not available)

And this test now fails with a JavaScript error:

http://www.formfaces.com/faces/Examples/Test%20Pages/controls-labels.html

SyntaxError: Parse error
http://www.formfaces.com/faces/Source/xforms.js
Line: 1

Almost there!

</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>86440</commentid>
    <comment_count>4</comment_count>
    <who name="Oliver Hunt">oliver</who>
    <bug_when>2008-07-19 23:39:33 -0700</bug_when>
    <thetext>That last example doesn&apos;t seem to trigger an exception in ToT</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>450602</commentid>
    <comment_count>5</comment_count>
    <who name="Gavin Barraclough">barraclough</who>
    <bug_when>2011-08-12 13:10:41 -0700</bug_when>
    <thetext>http://www.formfaces.com/ seems to no longer exist. :-(</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>