pjsua_buddy_config

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

 



Hi!

Do I have to create a new pjsua_buddy_config for each buddy I add to 
pjsua or can I reuse the structure?

e.g.

pjsua_buddy_config buddy_cfg;
pjsua_buddy_config_default(&buddy_cfg);
buddy_cfg.uri = pj_str("sip:buddy1 at domain");
pjsua_buddy_add(&buddy_cfg, &buddyId1);
buddy_cfg.uri = pj_str("sip:buddy2 at domain");
pjsua_buddy_add(&buddy_cfg, &buddyId2);

or do I have to use:

pjsua_buddy_config buddy_cfg1;
pjsua_buddy_config buddy_cfg2;
pjsua_buddy_config_default(&buddy_cfg1);
pjsua_buddy_config_default(&buddy_cfg2);
buddy_cfg1.uri = pj_str("sip:buddy1 at domain");
buddy_cfg2.uri = pj_str("sip:buddy2 at domain");
pjsua_buddy_add(&buddy_cfg1, &buddyId1);
pjsua_buddy_add(&buddy_cfg2, &buddyId2);

btw: does pjsua makes a copy of all the config structures (account cfg, 
buddy cfg, transport cfg ...) so that they can be temporarily or does 
pjsua keep pointers to the config structures?

thanks
klaus





[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