ice_demo never initiates a session - char *role = strtok(NULL, SEP) -> role == 0

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

 



Hello,

I'm trying to use pjnath to create a P2P IM (for demo purposes). and
ultimately to transfer files. Are there any demos I could try out?

I thought the ice_demo<http://www.pjsip.org/pjnath/docs/html/ice__demo__sample.htm>was
a solution:
1. cmd-1: I launched a *pjturn-srv*
2. cmd2: icedemo.exe -s localhost:34780 (reading the port no from the
server). Server made no reaction.
3. cmd2: c
4. cmd2: i
error: Role required

I look into the ice_demo code and I notice:

01078         *const char *SEP = " \t\r\n";*


else if (strcmp(cmd, "init")==0 || strcmp(cmd, "i")==0) {
01107
01108             *char *role = strtok(NULL, SEP);*
01109             if (role)
01110                 icedemo_init_session(*role);
01111             else
01112                 puts("error: Role required");
01113
01114         }

isn't role always going to be null?


-- 
Regards,
K. Gabriele

--- unchanged since 20/9/10 ---
P.S. If the subject contains "[LON]" or the addressee acknowledges the
receipt within 48 hours then I don't resend the email.
subject(this) ? L(LON*) ? ?x. (x ? MyInbox ? Acknowledges(x, this) ? time(x)
< Now + 48h) ? ?resend(I, this).

If an email is sent by a sender that is not a trusted contact or the email
does not contain a valid code then the email is not received. A valid code
starts with a hyphen and ends with "X".
?x. x ? MyInbox ? from(x) ? MySafeSenderList ? (?y. y ? subject(x) ? y ?
L(-[a-z]+[0-9]X)).
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20101211/73cdf404/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