当前位置:编程学习 > wap >>

sip注册之后发起invite遇到的问题

参考的自带的sip的例子。

注册成功之后发起invite,函数如下:

void CSIPExSIPIdleState::SendInviteL(
    CSIPExSIPEngine& aEngine,
        const TDesC8& aSipUri )
        {
        // Retrieve the active profile and connection
        CSIPProfile& prof = aEngine.Profile();
        CSIPConnection& conn = aEngine.ConnectionL();

    // Create CUri8 from passed descriptor
    CUri8* uri8 = aEngine.ConvertToUri8LC( aSipUri );

        // Get dialog association, save for future use
        // The ownership of uri8 is transferred
        CSIPInviteDialogAssoc* dialogAssoc =
                CSIPInviteDialogAssoc::NewL( conn, uri8, prof );
        CleanupStack::Pop( uri8 );

        aEngine.SetDialogAssoc( *dialogAssoc ); //Ownership is transferred!!

        // Create the necessary message elements
        CSIPMessageElements* msgElements = aEngine.CreateMessageElementsLC();

        // Send the INVITE in the dialog
        // The ownership of msgElements is transferred
        CSIPClientTransaction* tx = dialogAssoc->SendInviteL( msgElements );    //执行到这里就没有反应了
        CleanupStack::Pop( msgElements );

        // Save the pointer to the transaction to the Engine
        aEngine.SetClientTx( tx );

        // Change machine state
        aEngine.SetCurrentState( iClientEstablishingState );
        }

我想要是出错也应该有个回复啊?
还有这个invite出去之后回调的那个函数?
是  MSIPConnectionObserver 的 IncomingResponse 或者 ErrorOccured 吗?
望指教,感谢!! --------------------编程问答-------------------- 很想知道你是怎么注册的,我连注册都没搞定
补充:移动开发 ,  Symbian
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,