Review Request: KJS: No longer treat invalid hex as string

2 views
Skip to first unread message

Bernd Buschinski

unread,
Feb 25, 2012, 11:31:26 AM2/25/12
to kdelibs, Bernd Buschinski
This is an automatically generated e-mail. To reply, visit: http://git.reviewboard.kde.org/r/104076/

Review request for kdelibs.
By Bernd Buschinski.

Description

KJS: No longer treat invalid hex as string

Fixes ecmascript
- S7.8.4_A6.1_T4 (invalid hex \x0G)
- S7.8.4_A6.2_T1 & S7.8.4_A6.2_T2 (too short hex \xA)

Testing

tested with ecmascript, no new regressions

Diffs

  • kjs/lexer.cpp (e89de5f)

View Diff

Maks Orlovich

unread,
Mar 20, 2012, 5:18:17 PM3/20/12
to Maks Orlovich, kdelibs, Bernd Buschinski
This is an automatically generated e-mail. To reply, visit: http://git.reviewboard.kde.org/r/104076/

This is consistent with the spec; but I am worried that in the wild behavior may not match the spec yet (at least it doesn't for Chrome 18; it may be safe since FF seems to follow this, but I don't have a good version at spec now)

kjs/lexer.cpp (Diff revision 1)
int Lexer::lex()
320
        setDone(String);
320
        setDone(String);
Any reason you're still permitting this recovery (testcase: "\x")?


- Maks


On February 25th, 2012, 4:31 p.m., Bernd Buschinski wrote:

Review request for kdelibs.
By Bernd Buschinski.

Updated Feb. 25, 2012, 4:31 p.m.

Bernd Buschinski

unread,
Mar 21, 2012, 7:50:34 PM3/21/12
to Maks Orlovich, kdelibs, Bernd Buschinski
This is an automatically generated e-mail. To reply, visit: http://git.reviewboard.kde.org/r/104076/

On March 20th, 2012, 9:18 p.m., Maks Orlovich wrote:

kjs/lexer.cpp (Diff revision 1)
int Lexer::lex()
320
        setDone(String);
320
        setDone(String);
Any reason you're still permitting this recovery (testcase: "\x")?

Because I feared it would break even more, or rather there was some string appending magic that would make it valid.
In but there should be no way, \x must be followed by 2 valid hex values. I will update the patch

- Bernd

Reply all
Reply to author
Forward
0 new messages