Commit aa07e16e authored by Tristan Matthews's avatar Tristan Matthews
Browse files

* #6554: cleanup, refactoring in sipvoiplink

parent 474b2d6c
......@@ -1703,7 +1703,7 @@ void ManagerImpl::peerRingingCall (const std::string& id)
{
_debug ("Manager: Peer call %s ringing", id.c_str());
if (isCurrentCall (id))
if (isCurrentCall(id))
ringback();
_dbus.getCallManager()->callStateChanged (id, "RINGING");
......
This diff is collapsed.
......@@ -36,7 +36,6 @@
#define SIPVOIPLINK_H
#include <map>
#include <exception>
//////////////////////////////
/* PJSIP imports */
......@@ -57,9 +56,6 @@ class EventThread;
class SIPCall;
class SIPAccount;
#define RANDOM_LOCAL_PORT ((rand() % 27250) + 5250)*2
#define RANDOM_SIP_PORT rand() % 64000 + 1024
// To set the verbosity. From 0 (min) to 6 (max)
#define PJ_LOG_LEVEL 0
......@@ -296,11 +292,6 @@ class SIPVoIPLink : public VoIPLink
*/
bool sendTextMessage (sfl::InstantMessaging *module, const std::string& callID, const std::string& message, const std::string& from);
/**
* when we init the listener, how many times we try to bind a port?
*/
int _nbTryListenAddr;
/**
* Create the default UDP transport according ot Ip2Ip profile settings
*/
......@@ -333,7 +324,7 @@ class SIPVoIPLink : public VoIPLink
SIPVoIPLink ();
/* The singleton instance */
static SIPVoIPLink* _instance;
static SIPVoIPLink* instance_;
/**
* Initialize the PJSIP library
......@@ -422,28 +413,17 @@ class SIPVoIPLink : public VoIPLink
* UDP Transports are stored in this map in order to retreive them in case
* several accounts would share the same port number.
*/
std::map<pj_uint16_t, pjsip_transport*> _transportMap;
/**
* For registration use only
*/
int _regPort;
std::map<pj_uint16_t, pjsip_transport*> transportMap_;
/**
* Threading object
*/
EventThread* _evThread;
EventThread* evThread_;
/**
* Global mutex for the sip voiplink
*/
ost::Mutex _mutexSIP;
/**
* Number of SIP accounts connected to the link
*/
int _clients;
ost::Mutex mutexSIP_;
friend class SIPTest;
};
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment