Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
How to add null character at end in QString.
Indrajeet last edited by
How to add NULL character '\0' at the end of QString.
koahnig last edited by
Is there a particular reason to add the null character at the end?
You do not need in typical applications.
lgeyer last edited by
Every method, that allows for gaining access to the raw data of QString, like QString::data() or QString::unicode(), automatically terminates the string with '\0'.
This isn't coincidentally related to "http://developer.qt.nokia.com/forums/viewthread/13631/":http://developer.qt.nokia.com/forums/viewthread/13631/, is it? If so, it would be actually useful to see how you pass the data around and how you convert them from QString to the native types.