Re: [gtkmm] Glib::ustring problems



Am Son, 2002-10-13 um 20.41 schrieb Tapan S. Parikh:
> 
> Thanks alot, good sleuthing!  Seems right to me...  Wonder why ustring
> wasnt null-terminated?

Because I used data() instead of c_str() in the glibmm charset
conversion functions.  If you look at the std::string source code you'll
see that c_str() checks whether the string is terminated and writes '\0'
to the end of the string if not.  Since we don't need the termination
it'd be silly to do this all the time.

--Daniel





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