WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
23298
Need to be tolerant of null style values passed to CSSStyleSelector::convertToLength
https://bugs.webkit.org/show_bug.cgi?id=23298
Summary
Need to be tolerant of null style values passed to CSSStyleSelector::convertT...
Chris Marrin
Reported
2009-01-13 11:30:50 PST
For future functionality, we need to not crash when a null style is passed to this function. The only place it is used is in EMS and EXS computations. In this case, we will return !ok and not crash.
Attachments
Patch
(1.93 KB, patch)
2009-01-13 11:40 PST
,
Chris Marrin
darin
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Chris Marrin
Comment 1
2009-01-13 11:40:39 PST
Created
attachment 26677
[details]
Patch
Darin Adler
Comment 2
2009-01-13 11:49:04 PST
Comment on
attachment 26677
[details]
Patch
> + if (!style && (type == CSSPrimitiveValue::CSS_EMS || type == CSSPrimitiveValue::CSS_EXS)) { > + if (ok) > + *ok = false; > + } > + else if (type > CSSPrimitiveValue::CSS_PERCENTAGE && type < CSSPrimitiveValue::CSS_DEG)
Brace goes on same line as else in the WebKit coding style. r=me
Chris Marrin
Comment 3
2009-01-13 14:10:12 PST
I will make that change when I checkin
Chris Marrin
Comment 4
2009-01-13 14:47:29 PST
Sending WebCore/ChangeLog Sending WebCore/css/CSSStyleSelector.cpp Transmitting file data .. Committed revision 39878.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug