mirror of
https://github.com/signalwire/freeswitch.git
synced 2026-10-24 04:04:16 +00:00
Fix for -Wunused-but-set-variable required compiler. : mod_freetdm mod_avmd mod_cidlookup mod_ladspa mod_lcr mod_nibblebill mod_rss mod_vdm mod_dahdi_codec mod_skinny mod_cdr_pg_csv
This commit is contained in:
1 parent
5bcf487df9
commit
ba7dc9fde8
13 files changed
+23
-44
No files matched your search
@@ -251,7 +251,7 @@ PaError OpenAudioStream(PABLIO_Stream ** rwblPtr,
|
||||
PABLIO_Stream *aStream;
|
||||
long numFrames;
|
||||
//long numBytes;
|
||||
int channels = 1;
|
||||
//int channels = 1;
|
||||
|
||||
if (!(inputParameters || outputParameters)) {
|
||||
return -1;
|
||||
@@ -262,11 +262,13 @@ PaError OpenAudioStream(PABLIO_Stream ** rwblPtr,
|
||||
switch_assert(aStream);
|
||||
memset(aStream, 0, sizeof(PABLIO_Stream));
|
||||
|
||||
/*
|
||||
if (inputParameters) {
|
||||
channels = inputParameters->channelCount;
|
||||
} else if (outputParameters) {
|
||||
channels = outputParameters->channelCount;
|
||||
}
|
||||
*/
|
||||
|
||||
numFrames = RoundUpToNextPowerOf2(samples_per_packet * 5);
|
||||
aStream->bytesPerFrame = bytesPerSample;
|
||||
|
||||
@@ -462,7 +462,6 @@ uint32_t skinny_line_get_state(listener_t *listener, uint32_t line_instance, uin
|
||||
|
||||
switch_status_t skinny_tech_set_codec(private_t *tech_pvt, int force)
|
||||
{
|
||||
int ms;
|
||||
switch_status_t status = SWITCH_STATUS_SUCCESS;
|
||||
int resetting = 0;
|
||||
|
||||
@@ -542,7 +541,7 @@ switch_status_t skinny_tech_set_codec(private_t *tech_pvt, int force)
|
||||
}
|
||||
|
||||
tech_pvt->read_frame.rate = tech_pvt->rm_rate;
|
||||
ms = tech_pvt->write_codec.implementation->microseconds_per_packet / 1000;
|
||||
//ms = tech_pvt->write_codec.implementation->microseconds_per_packet / 1000;
|
||||
|
||||
if (!switch_core_codec_ready(&tech_pvt->read_codec)) {
|
||||
switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), SWITCH_LOG_ERROR, "Can't load codec?\n");
|
||||
@@ -880,7 +879,6 @@ switch_status_t channel_read_frame(switch_core_session_t *session, switch_frame_
|
||||
{
|
||||
switch_channel_t *channel = switch_core_session_get_channel(session);
|
||||
private_t *tech_pvt = switch_core_session_get_private(session);
|
||||
int payload = 0;
|
||||
|
||||
while (!(tech_pvt->read_codec.implementation && switch_rtp_ready(tech_pvt->rtp_session))) {
|
||||
if (switch_channel_ready(channel)) {
|
||||
@@ -908,7 +906,7 @@ switch_status_t channel_read_frame(switch_core_session_t *session, switch_frame_
|
||||
return SWITCH_STATUS_FALSE;
|
||||
}
|
||||
|
||||
payload = tech_pvt->read_frame.payload;
|
||||
//payload = tech_pvt->read_frame.payload;
|
||||
|
||||
if (switch_rtp_has_dtmf(tech_pvt->rtp_session)) {
|
||||
switch_dtmf_t dtmf = { 0 };
|
||||
|
||||
@@ -588,14 +588,12 @@ switch_call_cause_t skinny_ring_lines(private_t *tech_pvt, switch_core_session_t
|
||||
|
||||
switch_status_t skinny_session_ring_out(switch_core_session_t *session, listener_t *listener, uint32_t line_instance)
|
||||
{
|
||||
switch_channel_t *channel = NULL;
|
||||
private_t *tech_pvt = NULL;
|
||||
|
||||
switch_assert(session);
|
||||
switch_assert(listener);
|
||||
switch_assert(listener->profile);
|
||||
|
||||
channel = switch_core_session_get_channel(session);
|
||||
tech_pvt = switch_core_session_get_private(session);
|
||||
|
||||
send_start_tone(listener, SKINNY_TONE_ALERT, 0, line_instance, tech_pvt->call_id);
|
||||
@@ -732,14 +730,12 @@ switch_status_t skinny_session_start_media(switch_core_session_t *session, liste
|
||||
|
||||
switch_status_t skinny_session_hold_line(switch_core_session_t *session, listener_t *listener, uint32_t line_instance)
|
||||
{
|
||||
switch_channel_t *channel = NULL;
|
||||
private_t *tech_pvt = NULL;
|
||||
|
||||
switch_assert(session);
|
||||
switch_assert(listener);
|
||||
switch_assert(listener->profile);
|
||||
|
||||
channel = switch_core_session_get_channel(session);
|
||||
tech_pvt = switch_core_session_get_private(session);
|
||||
|
||||
skinny_session_stop_media(session, listener, line_instance);
|
||||
@@ -760,17 +756,15 @@ switch_status_t skinny_session_hold_line(switch_core_session_t *session, listene
|
||||
|
||||
switch_status_t skinny_session_unhold_line(switch_core_session_t *session, listener_t *listener, uint32_t line_instance)
|
||||
{
|
||||
switch_channel_t *channel = NULL;
|
||||
private_t *tech_pvt = NULL;
|
||||
|
||||
switch_assert(session);
|
||||
switch_assert(listener);
|
||||
switch_assert(listener->profile);
|
||||
|
||||
channel = switch_core_session_get_channel(session);
|
||||
tech_pvt = switch_core_session_get_private(session);
|
||||
|
||||
skinny_hold_active_calls(listener);
|
||||
skinny_hold_active_calls(listener);
|
||||
send_set_ringer(listener, SKINNY_RING_OFF, SKINNY_RING_FOREVER, 0, tech_pvt->call_id);
|
||||
send_set_speaker_mode(listener, SKINNY_SPEAKER_ON);
|
||||
send_select_soft_keys(listener, line_instance, tech_pvt->call_id, SKINNY_KEY_SET_RING_OUT, 0xffff);
|
||||
@@ -825,14 +819,12 @@ switch_status_t skinny_session_transfer(switch_core_session_t *session, listener
|
||||
|
||||
switch_status_t skinny_session_stop_media(switch_core_session_t *session, listener_t *listener, uint32_t line_instance)
|
||||
{
|
||||
switch_channel_t *channel = NULL;
|
||||
private_t *tech_pvt = NULL;
|
||||
|
||||
switch_assert(session);
|
||||
switch_assert(listener);
|
||||
switch_assert(listener->profile);
|
||||
|
||||
channel = switch_core_session_get_channel(session);
|
||||
tech_pvt = switch_core_session_get_private(session);
|
||||
|
||||
switch_clear_flag_locked(tech_pvt, TFLAG_IO);
|
||||
@@ -1773,7 +1765,6 @@ switch_status_t skinny_handle_soft_key_event_message(listener_t *listener, skinn
|
||||
uint32_t call_id = 0;
|
||||
switch_core_session_t *session = NULL;
|
||||
switch_channel_t *channel = NULL;
|
||||
private_t *tech_pvt = NULL;
|
||||
|
||||
skinny_check_data_length(request, sizeof(request->data.soft_key_event.event));
|
||||
|
||||
@@ -1790,7 +1781,6 @@ switch_status_t skinny_handle_soft_key_event_message(listener_t *listener, skinn
|
||||
break;
|
||||
case SOFTKEY_NEWCALL:
|
||||
status = skinny_create_incoming_session(listener, &line_instance, &session);
|
||||
tech_pvt = switch_core_session_get_private(session);
|
||||
|
||||
skinny_session_process_dest(session, listener, line_instance, NULL, '\0', 0);
|
||||
break;
|
||||
@@ -1874,13 +1864,10 @@ switch_status_t skinny_handle_unregister(listener_t *listener, skinny_message_t
|
||||
switch_status_t skinny_handle_soft_key_template_request(listener_t *listener, skinny_message_t *request)
|
||||
{
|
||||
skinny_message_t *message;
|
||||
skinny_profile_t *profile;
|
||||
|
||||
switch_assert(listener->profile);
|
||||
switch_assert(listener->device_name);
|
||||
|
||||
profile = listener->profile;
|
||||
|
||||
message = switch_core_alloc(listener->pool, 12+sizeof(message->data.soft_key_template));
|
||||
message->type = SOFT_KEY_TEMPLATE_RES_MESSAGE;
|
||||
message->length = 4 + sizeof(message->data.soft_key_template);
|
||||
|
||||
Reference in new issue
Block a user