Commit 64b5de44 authored by Alexandre Savard's avatar Alexandre Savard

#12896: Fix echo suppressor memory alocation problem

parent 1f21141d
......@@ -86,7 +86,7 @@ void AudioRtpFactory::initConfig()
void AudioRtpFactory::initSession()
{
DEBUG("AudioRtpFactory: init session");
DEBUG("AudioRtpFactory: init session2");
ost::MutexLock m(audioRtpThreadMutex_);
if (srtpEnabled_) {
......
......@@ -95,7 +95,7 @@ AudioRtpRecord::~AudioRtpRecord()
AudioRtpRecordHandler::AudioRtpRecordHandler(SIPCall &call) :
audioRtpRecord_(),
id_(call.getCallId()),
echoCanceller(call.getMemoryPool()),
// echoCanceller(call.getMemoryPool()),
gainController(8000, -10.0)
{}
......@@ -173,8 +173,8 @@ int AudioRtpRecordHandler::processDataEncode()
audioRtpRecord_.fadeInDecodedData(samples);
if (Manager::instance().getEchoCancelState())
echoCanceller.getData(micData);
// if (Manager::instance().getEchoCancelState())
// echoCanceller.getData(micData);
SFLDataFormat *out = micData;
......@@ -249,8 +249,8 @@ void AudioRtpRecordHandler::processDataDecode(unsigned char *spkrData, size_t si
mainBufferSampleRate, inSamples);
}
if (Manager::instance().getEchoCancelState())
echoCanceller.putData(out, outSamples);
// if (Manager::instance().getEchoCancelState())
// echoCanceller.putData(out, outSamples);
Manager::instance().getMainBuffer()->putData(out, outSamples * sizeof(SFLDataFormat), id_);
}
......
......@@ -174,7 +174,7 @@ class AudioRtpRecordHandler {
private:
const std::string id_;
EchoSuppress echoCanceller;
// EchoSuppress echoCanceller;
GainControl gainController;
};
}
......
......@@ -59,14 +59,21 @@ DBusManager::DBusManager() : callManager_(0)
#endif
{
try {
DEBUG("DBUS init threading");
DBus::_init_threading();
DEBUG("DBUS instantiate default dispatcher");
DBus::default_dispatcher = &dispatcher_;
DEBUG("DBUS session connection to session bus");
DBus::Connection sessionConnection(DBus::Connection::SessionBus());
DEBUG("DBUS request org.sflphone.SFLphone from session connection");
sessionConnection.request_name("org.sflphone.SFLphone");
DEBUG("DBUS create call manager from session connection");
callManager_ = new CallManager(sessionConnection);
DEBUG("DBUS create configuration manager from session connection");
configurationManager_ = new ConfigurationManager(sessionConnection);
DEBUG("DBUS create instance manager from session connection");
instanceManager_ = new Instance(sessionConnection);
#ifdef SFL_VIDEO
......@@ -74,7 +81,9 @@ DBusManager::DBusManager() : callManager_(0)
#endif
#ifdef USE_NETWORKMANAGER
DEBUG("DBUS system connection to system bus");
DBus::Connection systemConnection(DBus::Connection::SystemBus());
DEBUG("DBUS create the network manager from the system bus");
networkManager_ = new NetworkManager(systemConnection, "/org/freedesktop/NetworkManager", "");
#endif
......@@ -82,6 +91,8 @@ DBusManager::DBusManager() : callManager_(0)
ERROR("%s: %s, exiting\n", err.name(), err.what());
::exit(EXIT_FAILURE);
}
DEBUG("DBUS registration done");
}
DBusManager::~DBusManager()
......
......@@ -421,8 +421,7 @@ SIPVoIPLink::SIPVoIPLink() : sipTransport(endpt_, cp_, pool_), evThread_(this)
TRY(pj_init());
TRY(pjlib_util_init());
// From 0 (min) to 6 (max)
// pj_log_set_level(Logger::getDebugMode() ? 6 : 0);
pj_log_set_level(0);
pj_log_set_level(6);
TRY(pjnath_init());
pj_caching_pool_init(cp_, &pj_pool_factory_default_policy, 0);
......
Markdown is supported
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