diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2015-07-24 23:31:44 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2015-07-24 23:31:44 +0000 |
| commit | fae4db6d2c975173a6768bd4984eb707265f4e43 (patch) | |
| tree | 5f2a213743a58ba45d47aeb5e49f67d3e0b78981 /src/2geom/sbasis.cpp | |
| parent | astyle (diff) | |
| parent | 3D box tool: the shift key must not prevent snapping of the vanishing point. ... (diff) | |
| download | inkscape-fae4db6d2c975173a6768bd4984eb707265f4e43.tar.gz inkscape-fae4db6d2c975173a6768bd4984eb707265f4e43.zip | |
update to trunk
(bzr r13645.1.106)
Diffstat (limited to 'src/2geom/sbasis.cpp')
| -rw-r--r-- | src/2geom/sbasis.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/2geom/sbasis.cpp b/src/2geom/sbasis.cpp index 4f1df621e..42d92d7b8 100644 --- a/src/2geom/sbasis.cpp +++ b/src/2geom/sbasis.cpp @@ -328,9 +328,9 @@ SBasis derivative(SBasis const &a) { } int k = a.size()-1; double d = (2*k+1)*(a[k][1] - a[k][0]); - if(d == 0) + if (d == 0 && k > 0) { c.pop_back(); - else { + } else { c[k][0] = d; c[k][1] = d; } @@ -351,9 +351,9 @@ void SBasis::derive() { // in place version } int k = size()-1; double d = (2*k+1)*((*this)[k][1] - (*this)[k][0]); - if(d == 0) + if (d == 0 && k > 0) { pop_back(); - else { + } else { (*this)[k][0] = d; (*this)[k][1] = d; } |
