Added a free space function to the T.31 modem in spandsp, so the app doesn't

need to probe around inside the modem.
This commit is contained in:
Steve Underwood committed 2012-09-04 08:58:43 +08:00
1 parent f3cd4f41a0
commit 7c6f6e306c
4 files changed
+16 -4

No files matched your search

@@ -1279,7 +1279,7 @@ static void *SWITCH_THREAD_FUNC modem_thread(switch_thread_t *thread, void *obj)
modem->last_event = switch_time_now();
}
avail = sizeof(buf) - modem->t31_state->tx.in_bytes + modem->t31_state->tx.out_bytes - 1;
avail = t31_at_rx_free_space(modem->t31_state);
if (avail == 0) {
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_WARNING, "Buffer Full, retrying....\n");