Working with string - back to null terminated

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

 



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>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux