Skip to content
Snippets Groups Projects
Commit 85a4a861 authored by Alexandre Savard's avatar Alexandre Savard
Browse files

[#2464] IAX: Fix occasional arythmetic exception when sending data from mic

parent cdda2110
No related branches found
No related tags found
No related merge requests found
......@@ -364,7 +364,7 @@ IAXVoIPLink::sendAudioFromMic (void)
_mutexIAX.enterMutex();
// Make sure the session and the call still exists.
if (currentCall->getSession() && micDataEncoded != NULL) {
if (currentCall->getSession() && (micDataEncoded != NULL) && (nbSample_ > 0)) {
if (iax_send_voice (currentCall->getSession(), currentCall->getFormat(), micDataEncoded, compSize, nbSample_) == -1) {
_debug ("IAX: Error sending voice data.\n");
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment