Author vstinner
Recipients benjamin.peterson, docs@python, martin.panter, r.david.murray, vstinner, zbysz
Date 2014-12-18.08:13:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <CAMpsgwYGap_NJk8uboi58jiqzHd2kgyMqHEpL-nTfqGqrJ82sA@mail.gmail.com>
In-reply-to <1418880300.53.0.182606524162.issue21071@psf.upfronthosting.co.za>
Content
> Is it safe to assume PyUnicode_AsUTF8() is null-terminated?

Yes, Python ensures that the string is null terminated.

> (like PyBytes_AS_STRING() is)

Yes, PyBytes_AS_STRING() also ends with a null byte.

By the way, Unicode strings internally ends with a null character.
History
Date User Action Args
2014-12-18 08:13:13vstinnersetrecipients: + vstinner, benjamin.peterson, r.david.murray, zbysz, docs@python, martin.panter
2014-12-18 08:13:13vstinnerlinkissue21071 messages
2014-12-18 08:13:13vstinnercreate