Hello All,

Regarding my previous Email on this subject (see below), here is the Linux
console output with DEBUG LEVEL set to 5:

# bin/tcphone_app
Invoking ce_ProcUnreg...
Now Invoking su_init()...
Returned from su_init()...
Now Invoking su_home_init()...
Returned from su_home_init()...
Now Invoking su_root_create()...
su_port_create() called
su_port_create() returns 0x1000fe10
Returned from su_root_create(): appl->root=0x10010820...
Now Invoking nua_create()...
nua: nua_create: entering
su_port_create() called
su_port_create() returns 0x10012af8
nua: nua_stack_init: entering
nua: nua_stack_set_params: entering
soa_create("default", 0x10010ab0, 0x100135f8) called
soa_set_params(static::0x10013990, ...) called
nta_agent_create: initialized hash tables
nta_agent_create: initialized transports
nta_agent_create: initialized random identifiers
nta_agent_create: initialized timer
nta_agent_create: initialized resolver
tport_create(): 0x10014c20
nta: master transport created
tport_bind_server(0x10014c20) to */192.168.72.191:5060/sip
tport_bind_server(0x10014c20): calling tport_listen for udp
tport_alloc_primary(0x10014c20): new primary tport 0x10015018
tport_listen(0x10015018): listening at udp/192.168.72.191:5060/sip
tport_bind_server(0x10014c20): calling tport_listen for tcp
tport_alloc_primary(0x10014c20): new primary tport 0x100152b0
tport_listen(0x100152b0): listening at tcp/192.168.72.191:5060/sip
nta: bound to (192.168.72.191:5060;transport=*)
nta: agent_init_via: SIP/2.0/udp 192.168.72.191 (sip)
nta: agent_init_via: SIP/2.0/tcp 192.168.72.191 (sip)
nta: Via fields initialized
nta: Contact header created
nua_register: Adding contact URL '192.168.72.191' to list.
su_root_yeld [1]: 10010ab0 10010abc 10012af8
su_root_yeld [2]: 10012af8 1000b0c0 58 54 50b3c8
Returned from nua_create(): appl->nua=0x10010848...
nua: nh_create_handle: entering
Returned from nua_handle(): handle=0x100158e8...
nua: nua_register: entering
nua(0x100158e8): signal r_register
nua: nua_stack_set_params: entering
soa_clone(static::0x10013990, 0x10010ab0, 0x100158e8) called
soa_set_params(static::0x10015c48, ...) called
soa_set_params(static::0x10015c48, ...) called
nua(0x100158e8): adding register usage
nta_leg_create(0x100163e8)
nta: selecting scheme sip
tport_tsend(0x10015018) tpn = */192.168.72.130:5060
tport_resolve addrinfo = 192.168.72.130:5060
tport_by_addrinfo(0x10015018): not found by name */192.168.72.130:5060
tport_vsend(0x10015018): 486 bytes of 486 to */192.168.72.130:5060
tport_vsend returned 486
nta: sent REGISTER (9624869) to */192.168.72.130:5060
su_port_destroy() called
su_port_destroy() close mailbox
su_port_destroy() freed registrations
su_port_destroy() returns
nta: timer E fired, retransmit REGISTER (9624869)
tport_tsend(0x10015018) tpn = */192.168.72.130:5060
tport_resolve addrinfo = 192.168.72.130:5060
tport_by_addrinfo(0x10015018): not found by name */192.168.72.130:5060
tport_vsend(0x10015018): 486 bytes of 486 to */192.168.72.130:5060
tport_vsend returned 486
nta: resent REGISTER (9624869) to */192.168.72.130:5060
tport_release(0x10015018): 0x10016980 by 0x100172d8 with (nil)
su_root_yeld [1]: 10010ab0 10010abc 10012af8
Segmentation fault
#

Best Regards,
Jerry


-----Original Message-----
From:
Sent: Tuesday, April 10, 2007 11:38 AM
To: '[email protected]'
Subject: REGISTRATION Segmentation Fault


Hello,

I am getting a Segmentation Fault after attempting to REGISTER a line (see
build configuration below).

The REGISTER request goes out and I get the "100 Trying" and "200 OK" reply
from our SIP server (see code excerpt below).  However, after a second or
two, the process encounters a Segmentation Fault and closes down the
process. The fault happens in su_root_yield() (See call flow below), and is
due to port->sup_vtable apparently getting corrupted.

I hope someone can help with this.

;------------------start build configuration-----------------------
==>
../configure -C --host=mips-linux --prefix=/home/jerryr/workspace/SipPhone_v
04/Apps/sofia-sip/build --with-glib=no --with-rt=no --enable-ndebug
;-------------------end build configuration------------------------


;------------------start call flow-----------------------
su_clone_main()
  su_root_run()
    su_port_run()
      su_port_run()
        su_timer_expire()
          agent_timer()
            outgoing_timer()
              su_root_yield()   <<-----Encounters Segmentation Fault
;-------------------end call flow------------------------


;------------------start code excerpt-----------------------
extern void ce_SipEventCb(
        nua_event_t event,      int status,             char const *phrase,
        nua_t *nua,             nua_magic_t *magic,     nua_handle_t *nh,
        nua_hmagic_t *hmagic,   sip_t const *sip,       tagi_t tags[]);
SIP_APPL appl[1] = {{{{sizeof(SIP_APPL)}}}};    // application context
structure

void main(void)
{
        su_init();
        su_home_init(appl->home);

        appl->root = su_root_create(NULL);
        if (NULL == appl->root) {printf("ROOT CREATE FAIL\n"); return;}

        appl->nua =
nua_create(appl->root,ce_SipEventCb,NULL,NUTAG_URL("sip:192.168.72.191:5060"
),TAG_END());
        if (NULL == appl->nua) {printf("NUA CREATE FAIL\n"); return;}

        nua_handle_t *handle;
        handle =
nua_handle(appl->nua,NULL,NUTAG_URL("sip:[EMAIL PROTECTED]:5060"),TAG_END(
));
        if (handle == NULL) {printf("ce_InitReg: nua_handle FAILED\n"); return;}
        nua_register(handle, TAG_NULL());

        su_root_run (appl->root);
        for (;;) sleep(2000);   // Loop endlessly here...
}
//------------------end code excerpt------------------------

Regards,
Jerry


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Sofia-sip-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sofia-sip-devel

Reply via email to