Commit fbf0aaca authored by Ronan's avatar Ronan

fix g++ build

parent aa548fa3
......@@ -62,13 +62,11 @@ static LinphoneCall * look_for_broken_call_to_replace(SalOp *h, LinphoneCore *lc
const bctbx_list_t *calls = linphone_core_get_calls(lc);
const bctbx_list_t *it = calls;
while (it != NULL) {
LinphoneCall *replaced_call = NULL;
#if 0
LinphoneCall *replaced_call = NULL;
LinphoneCall *call = (LinphoneCall *)bctbx_list_get_data(it);
#endif
SalOp *replaced_op = sal_call_get_replaces(h);
if (replaced_op) replaced_call = (LinphoneCall*)sal_op_get_user_pointer(replaced_op);
#if 0
if ((call->broken && sal_call_compare_op(h, call->op))
|| ((replaced_call == call) && (strcmp(sal_op_get_from(h), sal_op_get_from(replaced_op)) == 0) && (strcmp(sal_op_get_to(h), sal_op_get_to(replaced_op)) == 0))) {
return call;
......@@ -202,11 +200,11 @@ static void call_ringing(SalOp *h) {
L_GET_PRIVATE(session)->remoteRinging();
}
static void start_pending_refer(LinphoneCall *call){
#if 0
static void start_pending_refer(LinphoneCall *call){
linphone_core_start_refered_call(call->core, call,NULL);
#endif
}
#endif
/*
* could be reach :
......@@ -259,8 +257,8 @@ static void call_terminated(SalOp *op, const char *from) {
L_GET_PRIVATE(session)->terminated();
}
static int resume_call_after_failed_transfer(LinphoneCall *call){
#if 0
static int resume_call_after_failed_transfer(LinphoneCall *call){
if (call->was_automatically_paused && call->state==LinphoneCallPausing)
return BELLE_SIP_CONTINUE; /*was still in pausing state*/
......@@ -274,10 +272,8 @@ static int resume_call_after_failed_transfer(LinphoneCall *call){
}
linphone_call_unref(call);
return BELLE_SIP_STOP;
#else
return BELLE_SIP_STOP;
#endif
}
#endif
static void call_failure(SalOp *op) {
LinphonePrivate::CallSession *session = reinterpret_cast<LinphonePrivate::CallSession *>(sal_op_get_user_pointer(op));
......
......@@ -639,6 +639,7 @@ void linphone_call_set_next_video_frame_decoded_callback(LinphoneCall *call, Lin
void linphone_call_init_media_streams(LinphoneCall *call){
}
#if 0
static int dtmf_tab[16]={'0','1','2','3','4','5','6','7','8','9','*','#','A','B','C','D'};
static void linphone_core_dtmf_received(LinphoneCall *call, int dtmf){
......@@ -648,6 +649,7 @@ static void linphone_core_dtmf_received(LinphoneCall *call, int dtmf){
}
linphone_call_notify_dtmf_received(call, dtmf_tab[dtmf]);
}
#endif
void set_playback_gain_db(AudioStream *st, float gain){
if (st->volrecv){
......@@ -659,18 +661,22 @@ void set_playback_gain_db(AudioStream *st, float gain){
void _post_configure_audio_stream(AudioStream *st, LinphoneCore *lc, bool_t muted){
}
#if 0
static void setup_ring_player(LinphoneCore *lc, LinphoneCall *call){
int pause_time=3000;
audio_stream_play(call->audiostream,lc->sound_conf.ringback_tone);
ms_filter_call_method(call->audiostream->soundread,MS_FILE_PLAYER_LOOP,&pause_time);
}
#endif
#if 0
static bool_t linphone_call_sound_resources_available(LinphoneCall *call){
LinphoneCore *lc=call->core;
LinphoneCall *current=linphone_core_get_current_call(lc);
return !linphone_core_is_in_conference(lc) &&
(current==NULL || current==call);
}
#endif
void linphone_call_delete_upnp_session(LinphoneCall *call){
}
......@@ -943,6 +949,7 @@ void linphone_call_stop_recording(LinphoneCall *call) {
linphone_call_get_cpp_obj(call)->stopRecording();
}
#if 0
static void linphone_call_lost(LinphoneCall *call){
LinphoneCore *lc = call->core;
char *temp = NULL;
......@@ -959,6 +966,7 @@ static void linphone_call_lost(LinphoneCall *call){
linphone_core_play_named_tone(lc, LinphoneToneCallLost);
ms_free(temp);
}
#endif
/*do not change the prototype of this function, it is also used internally in linphone-daemon.*/
void linphone_call_stats_fill(LinphoneCallStats *stats, MediaStream *ms, OrtpEvent *ev){
......@@ -1067,7 +1075,7 @@ const LinphoneCallParams * linphone_call_get_params(LinphoneCall *call) {
return call->paramsCache;
}
#if 0
static int send_dtmf_handler(void *data, unsigned int revents){
LinphoneCall *call = (LinphoneCall*)data;
/*By default we send DTMF RFC2833 if we do not have enabled SIP_INFO but we can also send RFC2833 and SIP_INFO*/
......@@ -1100,6 +1108,7 @@ static int send_dtmf_handler(void *data, unsigned int revents){
return FALSE;
}
}
#endif
LinphoneStatus linphone_call_send_dtmf(LinphoneCall *call, char dtmf) {
#if 0
......@@ -1210,8 +1219,10 @@ LinphoneStatus linphone_call_resume(LinphoneCall *call) {
return linphone_call_get_cpp_obj(call)->resume();
}
#if 0
static void terminate_call(LinphoneCall *call) {
}
#endif
LinphoneStatus linphone_call_terminate(LinphoneCall *call) {
return linphone_call_get_cpp_obj(call)->terminate();
......@@ -1388,6 +1399,7 @@ void linphone_call_set_broken(LinphoneCall *call){
#endif
}
#if 0
static void linphone_call_repair_by_invite_with_replaces(LinphoneCall *call) {
const char *call_id = sal_op_get_call_id(call->op);
const char *from_tag = sal_call_get_local_tag(call->op);
......@@ -1397,6 +1409,7 @@ static void linphone_call_repair_by_invite_with_replaces(LinphoneCall *call) {
sal_call_set_replaces(call->op, call_id, from_tag, to_tag);
linphone_call_start_invite(call, NULL);
}
#endif
void linphone_call_reinvite_to_recover_from_connection_loss(LinphoneCall *call) {
#if 0
......
......@@ -243,6 +243,7 @@ const char *linphone_ice_state_to_string(LinphoneIceState state){
void linphone_call_update_ice_state_in_call_stats(LinphoneCall *call) {
}
#if 0
static void get_default_addr_and_port(uint16_t componentID, const SalMediaDescription *md, const SalStreamDescription *stream, const char **addr, int *port)
{
if (componentID == 1) {
......@@ -254,6 +255,7 @@ static void get_default_addr_and_port(uint16_t componentID, const SalMediaDescri
} else return;
if ((*addr)[0] == '\0') *addr = md->addr;
}
#endif
void linphone_call_clear_unused_ice_candidates(LinphoneCall *call, const SalMediaDescription *md){
#if 0
......
......@@ -44,6 +44,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
/*since printf family functions are LOCALE dependent, float separator may differ
depending on the user's locale (LC_NUMERIC environment var).*/
#if 0
static char * float_to_one_decimal_string(float f) {
float rounded_f = floorf(f * 10 + .5f) / 10;
......@@ -52,6 +53,7 @@ static char * float_to_one_decimal_string(float f) {
return ms_strdup_printf("%d.%d", floor_part, one_decimal_part);
}
#endif
static void append_to_buffer_valist(char **buff, size_t *buff_size, size_t *offset, const char *fmt, va_list args) {
belle_sip_error_code ret;
......@@ -81,12 +83,14 @@ static void append_to_buffer_valist(char **buff, size_t *buff_size, size_t *offs
}
}
#if 0
static void append_to_buffer(char **buff, size_t *buff_size, size_t *offset, const char *fmt, ...) {
va_list args;
va_start(args, fmt);
append_to_buffer_valist(buff, buff_size, offset, fmt, args);
va_end(args);
}
#endif
static void reset_avg_metrics(reporting_session_report_t * report){
int i;
......@@ -118,6 +122,7 @@ static void reset_avg_metrics(reporting_session_report_t * report){
#define METRICS_DELAY 1 << 4
#define METRICS_SIGNAL 1 << 5
#if 0
static uint8_t are_metrics_filled(const reporting_content_metrics_t *rm) {
uint8_t ret = 0;
......@@ -152,17 +157,16 @@ static uint8_t are_metrics_filled(const reporting_content_metrics_t *rm) {
return ret;
}
#endif
static bool_t quality_reporting_enabled(const LinphoneCall * call) {
#if 0
static bool_t quality_reporting_enabled(const LinphoneCall * call) {
return (call->dest_proxy != NULL && linphone_proxy_config_quality_reporting_enabled(call->dest_proxy));
#else
return FALSE;
#endif
}
#endif
static bool_t media_report_enabled(LinphoneCall * call, int stats_type){
#if 0
static bool_t media_report_enabled(LinphoneCall * call, int stats_type){
if (! quality_reporting_enabled(call))
return FALSE;
......@@ -173,11 +177,10 @@ static bool_t media_report_enabled(LinphoneCall * call, int stats_type){
return FALSE;
return (call->log->reporting.reports[stats_type] != NULL);
#else
return FALSE;
#endif
}
#endif
#if 0
static void append_metrics_to_buffer(char ** buffer, size_t * size, size_t * offset, const reporting_content_metrics_t *rm) {
char * timestamps_start_str = NULL;
char * timestamps_stop_str = NULL;
......@@ -273,7 +276,9 @@ static void append_metrics_to_buffer(char ** buffer, size_t * size, size_t * off
ms_free(moslq_str);
ms_free(moscq_str);
}
#endif
#if 0
static int send_report(LinphoneCall* call, reporting_session_report_t * report, const char * report_event) {
LinphoneContent *content;
size_t offset = 0;
......@@ -408,7 +413,9 @@ static int send_report(LinphoneCall* call, reporting_session_report_t * report,
return ret;
}
#endif
#if 0
static const SalStreamDescription * get_media_stream_for_desc(const SalMediaDescription * smd, SalStreamType sal_stream_type) {
int count;
if (smd != NULL) {
......@@ -420,6 +427,7 @@ static const SalStreamDescription * get_media_stream_for_desc(const SalMediaDesc
}
return NULL;
}
#endif
static void update_ip(LinphoneCall * call, int stats_type) {
#if 0
......@@ -450,6 +458,7 @@ static void update_ip(LinphoneCall * call, int stats_type) {
#endif
}
#if 0
static void qos_analyzer_on_action_suggested(void *user_data, int datac, const char** datav){
reporting_session_report_t *report = (reporting_session_report_t*)user_data;
LinphoneCall *call = report->call;
......@@ -492,6 +501,7 @@ static void qos_analyzer_on_action_suggested(void *user_data, int datac, const c
appendbuf=ms_strdup_printf("%s%s;", report->qos_analyzer.output?report->qos_analyzer.output:"", datav[3]);
STR_REASSIGN(report->qos_analyzer.output, appendbuf);
}
#endif
void linphone_reporting_update_ip(LinphoneCall * call) {
update_ip(call, LINPHONE_CALL_STATS_AUDIO);
......@@ -604,9 +614,11 @@ void linphone_reporting_update_media_info(LinphoneCall * call, int stats_type) {
}
/* generate random float in interval ] 0.9 t ; 1.1 t [*/
#if 0
static float reporting_rand(float t){
return t * (.2f * (rand() / (RAND_MAX * 1.0f)) + 0.9f);
}
#endif
void linphone_reporting_on_rtcp_update(LinphoneCall *call, SalStreamType stats_type) {
#if 0
......@@ -718,6 +730,7 @@ int linphone_reporting_publish_interval_report(LinphoneCall* call) {
return publish_report(call, "VQIntervalReport");
}
#if 0
static bool_t set_on_action_suggested_cb(MediaStream *stream,void (*on_action_suggested)(void*,int,const char**),void* u) {
if (stream&&stream->rc){
MSQosAnalyzer *analyzer=ms_bitrate_controller_get_qos_analyzer(stream->rc);
......@@ -730,6 +743,7 @@ static bool_t set_on_action_suggested_cb(MediaStream *stream,void (*on_action_su
}
return FALSE;
}
#endif
void linphone_reporting_call_state_updated(LinphoneCall *call){
#if 0
......
......@@ -26,7 +26,7 @@ LINPHONE_BEGIN_NAMESPACE
// =============================================================================
CallSessionParamsPrivate::CallSessionParamsPrivate (const CallSessionParamsPrivate &src) {
CallSessionParamsPrivate::CallSessionParamsPrivate (const CallSessionParamsPrivate &src) : ClonableObjectPrivate () {
sessionName = src.sessionName;
privacy = src.privacy;
inConference = src.inConference;
......
......@@ -3571,13 +3571,13 @@ void MediaSessionPrivate::executeBackgroundTasks (bool oneSecondElapsed) {
handleStreamEvents(mainVideoStreamIndex);
handleStreamEvents(mainTextStreamIndex);
#if 0
int disconnectTimeout = linphone_core_get_nortp_timeout(core);
bool disconnected = false;
if (((state == LinphoneCallStreamsRunning) || (state == LinphoneCallPausedByRemote)) && oneSecondElapsed && audioStream
&& (audioStream->ms.state == MSStreamStarted) && (disconnectTimeout > 0)) {
disconnected = !audio_stream_alive(audioStream, disconnectTimeout);
}
#if 0
if (disconnected)
linphone_call_lost(call);
#endif
......
This diff is collapsed.
......@@ -691,12 +691,13 @@ static void call_with_sips_not_achievable(void){
}
#if 0
static bool_t is_sending_ipv6(RtpSession *session, bool_t rtcp){
const struct sockaddr *dest = rtcp ? (struct sockaddr*)&session->rtcp.gs.rem_addr : (struct sockaddr*)&session->rtp.gs.rem_addr;
struct sockaddr_in6 *in6=(struct sockaddr_in6*)dest;
return dest->sa_family == AF_INET6 && !IN6_IS_ADDR_V4MAPPED(&in6->sin6_addr);
}
#endif
static bool_t is_remote_contact_ipv6(LinphoneCall *call){
const char *contact=linphone_call_get_remote_contact(call);
LinphoneAddress *ct_addr;
......
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