Google Groups unterstützt keine neuen Usenet-Beiträge oder ‑Abos mehr. Bisherige Inhalte sind weiterhin sichtbar.

Nav 4.X parsing bug - any thoughts?

1 Aufruf
Direkt zur ersten ungelesenen Nachricht

William J. Edney

ungelesen,
07.07.2001, 01:17:2707.07.01
an
Hi All -

Currently pressing towards release and we've come across a transient
parser bug in Nav 4.7. At some point, the parser freaks out and reports
'missing ) after for-loop control'. This bug floats around and appears
and disappears as script content is added and removed. Another clue: it
seems to have something to do with comments.

Again, this is in Nav 4.7 and does not appear to affect Mozilla (it runs
the exact same content - no problem).

Any and all help most appreciated.

Thanks!!

- Bill

Georg Maaß

ungelesen,
07.07.2001, 06:11:0907.07.01
an
William J. Edney wrote:

> Currently pressing towards release and we've come across a transient
> parser bug in Nav 4.7. At some point, the parser freaks out and reports
> 'missing ) after for-loop control'. This bug floats around and appears
> and disappears as script content is added and removed. Another clue: it
> seems to have something to do with comments.
>
> Again, this is in Nav 4.7 and does not appear to affect Mozilla (it runs
> the exact same content - no problem).

This bug is available in all NN4 implementations on all platforms. It is
discussed in the German news group de.comp.lang.javascript as NRLB
(Netscape Run Length Bug), because the location inside your code, where
the bug hits to, depends on code length.

The location, where the bug hits into your code depends on the platform
on Mac it hits with one code each time at the same location. On linux
it hits much less, but if it hits, then it hits with teh same code on
different locations. On Win9x it hits on a different location than on
Mac but each time on the same location. On Win NT it hits each time some
where else.

There are different variations of the bug. Most of them have to do with
document.write. Replacing all document.writeln by document.write may
help. Removing all trailing newlines from stuff generated via document
.write is also required. if you dynamically include something like:
document.write('<link rel="stylesheet" href="myshit.css">');
document.write('<script src="myscript.js"><\/script>');
you must remove all trailing linefeeds from the include files. This
helps to avoid the bug in most cases. But there are also variations
without document.write. For this other kind I don't know any work around
because I didn't find out, what's triggering the bug. The bug also has
to do with cache settings and timing during initial parse phase (before
onload). E.g. an interpution in this phase by an alert or a cookie
security request may have influence whether the bug occures or not.

Look at http://gml-modul.sourceforge.net/cgi-bin/gmL for an example,
where the bug hits into the HTML code destroying some tags. With dif-
ferent cgi parameters the bug hits into the JavaScript code causing
JavaScript errors.

I'm not sure whether the bug is also available on NN3, but I have the
suspect that it is older than NN4. I never detected this bug with Mozil-
la/5.

Greetings, Georg
--
Georg Maaß - bioshop.de D-20535 Hamburg, Sievekingsallee 35
JavaScript, C++ Engineering

- The ultimative DHTML engine: http://gml-modul.sourceforge.net -

0 neue Nachrichten