Hi. sprintf(buffer, "%.*s", ci.remote_info.slen, ci.remote_info.ptr) 06.06.2012 23:49, Gabriel Ortiz Lour ?????: > Hi all, > > Just a PJ begginer question. What's the best way to get null > terminated strings from pj_str_t to be able to do something like: > > *sprintf(buffer, "Incoming call from: %s", ci.remote_info.ptr);* > (this does not work since its not null terminated) > > Thanks, > Gabriel > > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip at lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20120606/fefcf60d/attachment.html>