Commit c050b244 authored by Ghislain MARY's avatar Ghislain MARY

Fix crash in quality reporting.

parent 50244176
......@@ -612,11 +612,11 @@ void linphone_reporting_on_rtcp_update(LinphoneCall *call, SalStreamType stats_t
int report_interval;
if (stats_type == 0) {
stats = L_GET_CPP_PTR_FROM_C_OBJECT(call)->getStats(LinphoneStreamTypeAudio);
stats = L_GET_PRIVATE_FROM_C_OBJECT(call)->getStats(LinphoneStreamTypeAudio);
} else if (stats_type == 1) {
stats = L_GET_CPP_PTR_FROM_C_OBJECT(call)->getStats(LinphoneStreamTypeVideo);
stats = L_GET_PRIVATE_FROM_C_OBJECT(call)->getStats(LinphoneStreamTypeVideo);
} else {
stats = L_GET_CPP_PTR_FROM_C_OBJECT(call)->getStats(LinphoneStreamTypeText);
stats = L_GET_PRIVATE_FROM_C_OBJECT(call)->getStats(LinphoneStreamTypeText);
}
if (! media_report_enabled(call,stats_type))
......
......@@ -59,6 +59,7 @@ public:
bool getRingingBeep () const { return ringingBeep; }
void setAudioMuted (bool value);
void setRingingBeep (bool value) { ringingBeep = value; }
LinphoneCallStats *getStats (LinphoneStreamType type) const;
void createPlayer () const;
......
......@@ -61,6 +61,10 @@ void CallPrivate::setAudioMuted (bool value) {
static_pointer_cast<MediaSession>(getActiveSession())->getPrivate()->setAudioMuted(value);
}
LinphoneCallStats *CallPrivate::getStats (LinphoneStreamType type) const {
return static_pointer_cast<const MediaSession>(getActiveSession())->getPrivate()->getStats(type);
}
// -----------------------------------------------------------------------------
void CallPrivate::initiateIncoming () {
......
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