graphics/inkscape commit r330754
Koop Mast
kwm at rainbow-runner.nl
Sat Oct 19 08:00:37 UTC 2013
On 19-10-2013 8:13, Boris Samorodov wrote:
> 18.10.2013 22:17, Tomasz Sowa пишет:
>> Hi
>>
>> Thank you for the update for compiling with clang. I have got a question
>> about one function:
>> void sp_item_rm_unsatisfied_cns(SPItem &item)
>> from src/sp-item-rm-unsatisfied-cns.cpp
>>
>> before patching it is:
>> void sp_item_rm_unsatisfied_cns(SPItem &item)
>> {
>> if (item.constraints.empty()) {
>> return;
>> }
>> std::vector<Inkscape::SnapCandidatePoint> snappoints;
>> sp_item_snappoints(&item, snappoints, NULL);
>> for (unsigned i = item.constraints.size(); i--;) {
>> g_assert( i < item.constraints.size() );
>> SPGuideConstraint const &cn = item.constraints[i];
>> int const snappoint_ix = cn.snappoint_ix;
>> g_assert( snappoint_ix < int(snappoints.size()) );
>> if (!approx_equal( sp_guide_distance_from_pt(cn.g,
>> snappoints[snappoint_ix].getPoint()), 0) ) {
>> remove_last(cn.g->attached_items, SPGuideAttachment(&item,
>> cn.snappoint_ix));
>> g_assert( i < item.constraints.size() );
>> vector<SPGuideConstraint>::iterator const
>> ei(&item.constraints[i]);
>> item.constraints.erase(ei);
>> }
>> }
>> }
>>
>> but after patching the last erase() is changed to:
>> item.constraints.erase(item.constraints.begin() + 1);
>>
>> and this is not the same, it propably should be:
>> item.constraints.erase(item.constraints.begin() + i);
> Yep, that seems to be a typo.
>
Fix thanks for the report, it took me a while to see that the but
actually was :)
-Koop
More information about the freebsd-ports
mailing list