gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnash-commit] gnash ChangeLog server/edit_text_character.cpp ...


From: zou lunkai
Subject: Re: [Gnash-commit] gnash ChangeLog server/edit_text_character.cpp ...
Date: Mon, 28 Apr 2008 13:28:41 +0800

In case you are working on the string iterator code, there's another
line triggers the limitation here:

edit_text_character.cpp, around line 1321:

std::wstring::const_iterator it = _text.begin();
while (boost::uint32_t code = *it++)  // <------- [2] also relys on
dereference the end
                                                     //
 iterator.

I am not sure who committed this code, but you may like to fix it together:).

--zou




On 4/28/08, Benjamin Wolsey <address@hidden> wrote:
> > But probably it is also implementation specific,
> >  since dereference the end() iterator is invalid in general. So, it's
> > not a good idea to presume string::const_iterator is the same as const
> > char *.
> >
> >
> > The code inside decodeNextUnicodeCharacter() is dependent on
> > dereference the end iterator, which also causes runtime assertion
> > here. I hope the explanation it's clear.
> >
>
> Very clear, and correct of course. Damn it - I *like* that string
> iterator :-(
>
>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]