Fix bug 638764: Error in rule_ellptical_arc crashes Scour, by applying the fix provided by Walther.
This commit is contained in:
parent
fee74ead24
commit
cd63079879
1 changed files with 2 additions and 2 deletions
|
|
@ -221,14 +221,14 @@ class SVGPathParser(object):
|
||||||
arguments = []
|
arguments = []
|
||||||
while token[0] in self.number_tokens:
|
while token[0] in self.number_tokens:
|
||||||
rx = Decimal(token[1]) * 1
|
rx = Decimal(token[1]) * 1
|
||||||
if rx < 0.0:
|
if rx < Decimal("0.0"):
|
||||||
raise SyntaxError("expecting a nonnegative number; got %r" % (token,))
|
raise SyntaxError("expecting a nonnegative number; got %r" % (token,))
|
||||||
|
|
||||||
token = next()
|
token = next()
|
||||||
if token[0] not in self.number_tokens:
|
if token[0] not in self.number_tokens:
|
||||||
raise SyntaxError("expecting a number; got %r" % (token,))
|
raise SyntaxError("expecting a number; got %r" % (token,))
|
||||||
ry = Decimal(token[1]) * 1
|
ry = Decimal(token[1]) * 1
|
||||||
if ry < 0.0:
|
if ry < Decimal("0.0"):
|
||||||
raise SyntaxError("expecting a nonnegative number; got %r" % (token,))
|
raise SyntaxError("expecting a nonnegative number; got %r" % (token,))
|
||||||
|
|
||||||
token = next()
|
token = next()
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue