Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(44)

Side by Side Diff: Source/core/css/parser/CSSPropertyParser.cpp

Issue 912383003: ASSERTION FAILED: !m_parsedCalculation in CSSPropertyParser::parseCalculation (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) 3 * Copyright (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com)
4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. 4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved.
5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> 5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com>
6 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> 6 * Copyright (C) 2008 Eric Seidel <eric@webkit.org>
7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
8 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. 8 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved.
9 * Copyright (C) 2012 Intel Corporation. All rights reserved. 9 * Copyright (C) 2012 Intel Corporation. All rights reserved.
10 * 10 *
(...skipping 5536 matching lines...) Expand 10 before | Expand all | Expand 10 after
5547 return nullptr; 5547 return nullptr;
5548 } 5548 }
5549 // The value is good. Commit it. 5549 // The value is good. Commit it.
5550 context.commitValue(); 5550 context.commitValue();
5551 } else if (validUnit(val, FLength, HTMLStandardMode)) { 5551 } else if (validUnit(val, FLength, HTMLStandardMode)) {
5552 // We required a length and didn't get one. Invalid. 5552 // We required a length and didn't get one. Invalid.
5553 if (!context.allowLength()) 5553 if (!context.allowLength())
5554 return nullptr; 5554 return nullptr;
5555 5555
5556 // Blur radius must be non-negative. 5556 // Blur radius must be non-negative.
5557 if (context.allowBlur && !validUnit(val, FLength | FNonNeg, HTMLStan dardMode)) 5557 if (context.allowBlur && ((m_parsedCalculation && m_parsedCalculatio n->isNegative())
5558 || !validUnit(val, FLength | FNonNeg, HTMLStandardMode)))
rune 2015/02/18 19:09:54 Won't this still hit the assert for positive calc
5558 return nullptr; 5559 return nullptr;
5559 5560
5560 // A length is allowed here. Construct the value and add it. 5561 // A length is allowed here. Construct the value and add it.
5561 context.commitLength(val); 5562 context.commitLength(val);
5562 } else if (val->id == CSSValueInset) { 5563 } else if (val->id == CSSValueInset) {
5563 if (!context.allowStyle) 5564 if (!context.allowStyle)
5564 return nullptr; 5565 return nullptr;
5565 5566
5566 context.commitStyle(val); 5567 context.commitStyle(val);
5567 } else { 5568 } else {
(...skipping 2978 matching lines...) Expand 10 before | Expand all | Expand 10 after
8546 } 8547 }
8547 } 8548 }
8548 8549
8549 if (!list->length()) 8550 if (!list->length())
8550 return nullptr; 8551 return nullptr;
8551 8552
8552 return list.release(); 8553 return list.release();
8553 } 8554 }
8554 8555
8555 } // namespace blink 8556 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698