Fwd: Buddy presence issue

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

 



---------- Forwarded message ----------
From: Yuvaraj R <yuvaraj@xxxxxxxxxxx>
Date: Mon, Sep 21, 2009 at 7:47 PM
Subject: Buddy presence issue
To: pjsip at list.pjsip.org


Hi All

I am  have trouble with  buddy presence

I want to set following status for buddy

1) Online

2)offline

3) Away

4) ideal


*Code :*
bool *ok;

pj_status_t status;

pj_bool_t online_status;

pjrpid_element elem;

enum status

{

Online,

Offline,

Busy,

Idle,

Away,

};

QMessageBox::information(0,"",QString("1"));

if(sipOn)

{

QMessageBox::information(0,"",QString("2"));

switch(text.toInt(ok,10))

{

case Online:

elem.activity = PJRPID_ACTIVITY_BUSY;

elem.note = pj_str("Busy");

online_status =PJ_TRUE;

break;

case Offline:

online_status =PJ_FALSE;

break;

case Idle:

elem.activity = PJRPID_ACTIVITY_UNKNOWN;

elem.note = pj_str("Idle");

online_status =PJ_TRUE;

break;

case Away:

elem.activity = PJRPID_ACTIVITY_AWAY;

elem.note = pj_str("Away");

break;

}

QMessageBox::information(0,"",QString("3"));

pjsua_acc_set_online_status2(acc_id, online_status, &elem);

QMessageBox::information(0,"",QString("4"));

}

Here QmessageBox is  Qt realated to verify the code (such as printf
statements).

When i am calling the pjsua_acc_set_online_status2(acc_id, online_status,
&elem); My application is crashing..


Can anybody say what is the reason.

Please help me.


Thanks

Yuvaraj R
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20090921/1655134d/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