Bug 39031 - CSSParser::parseColor() shouldn't alter 'color' unless passed a valid color string.
Summary: CSSParser::parseColor() shouldn't alter 'color' unless passed a valid color s...
Status: CLOSED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks: 35784
  Show dependency treegraph
 
Reported: 2010-05-12 15:54 PDT by Andreas Kling
Modified: 2010-05-14 08:40 PDT (History)
5 users (show)

See Also:


Attachments
Proposed patch (1.03 KB, patch)
2010-05-12 16:03 PDT, Andreas Kling
no flags Details | Formatted Diff | Diff
Proposed patch v2 (2.71 KB, patch)
2010-05-12 18:45 PDT, Andreas Kling
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Kling 2010-05-12 15:54:14 PDT
So says the comment above the function:

// color will only be changed when string contains a valid css color, making it
// possible to set up a default color.
Comment 1 Andreas Kling 2010-05-12 16:03:22 PDT
Created attachment 55910 [details]
Proposed patch
Comment 2 Andreas Kling 2010-05-12 16:26:16 PDT
I can't think of a good way to LayoutTest this, but it doesn't break any existing tests and is obviously correct (famous last words..)
Comment 3 Darin Adler 2010-05-12 18:21:59 PDT
Comment on attachment 55910 [details]
Proposed patch

How did you check all the call sites to make sure that none were depending on the old behavior?
Comment 4 Andreas Kling 2010-05-12 18:45:37 PDT
Created attachment 55927 [details]
Proposed patch v2

By insufficient grepping, apparently. :(
Updated patch to remove dependency on old behavior.
Comment 5 Darin Adler 2010-05-12 22:33:14 PDT
Comment on attachment 55927 [details]
Proposed patch v2

Looks OK. r=me
Comment 6 WebKit Commit Bot 2010-05-14 07:47:22 PDT
Comment on attachment 55927 [details]
Proposed patch v2

Clearing flags on attachment: 55927

Committed r59473: <http://trac.webkit.org/changeset/59473>
Comment 7 WebKit Commit Bot 2010-05-14 07:47:28 PDT
All reviewed patches have been landed.  Closing bug.
Comment 8 Simon Hausmann 2010-05-14 08:40:04 PDT
Revision r59473 cherry-picked into qtwebkit-2.0 with commit 2b20c8dabe7670fe4c99b83156cdd5f4544c8c30