On 07/06/12 17:38, Noel Grandin wrote:
> Hi
> 
> These patches convert various SV_DECL_PTRARR stuff to std::set and
> std::vector in the SVL and SVTOOLS modules.
> 
> Passes "make check" at global level, and compiled with debug=true

thanks, pushed.

although there was quite some DBGUTIL code in svtools that didn't build,
apparently the easy-hackers haven't cleaned up the DBG_ASSERTs there yet...

patch #4 does this:

>      if ( nDelFromLine != 0xFFFF )
> -        pTEParaPortion->GetLines().DeleteAndDestroy( nDelFromLine, 
> pTEParaPortion->GetLines().Count() - nDelFromLine );
> +        for( TextLines::iterator it = pTEParaPortion->GetLines().begin() + 
> nDelFromLine;
> +             it != pTEParaPortion->GetLines().end(); ++it )
> +            delete *it;
> +        pTEParaPortion->GetLines().erase( pTEParaPortion->GetLines().begin() 
> + nDelFromLine,
> +                                          pTEParaPortion->GetLines().end() );

which will happily construct a begin() + 0xFFFF iterator and pass that
to erase.

see, this is exactly why i have acquired the habit to always write { and
} for if statements and loops, even if the body is only one statement :)

_______________________________________________
LibreOffice mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice

Reply via email to