fix uuid_jitterbuffer edge case debugging a non-existant jb causing a seg

This commit is contained in:
Anthony Minessale 2011-02-11 20:15:06 -06:00
parent 02234ae87d
commit 88d410d314
2 changed files with 2 additions and 2 deletions

View File

@ -1366,7 +1366,7 @@ static switch_status_t sofia_receive_message(switch_core_session_t *session, swi
if (s && !strcmp(s, "off")) {
s = NULL;
}
switch_rtp_debug_jitter_buffer(tech_pvt->rtp_session, s);
status = switch_rtp_debug_jitter_buffer(tech_pvt->rtp_session, s);
goto end;
}

View File

@ -1875,7 +1875,7 @@ static void jb_logger(const char *file, const char *func, int line, int level, c
SWITCH_DECLARE(switch_status_t) switch_rtp_debug_jitter_buffer(switch_rtp_t *rtp_session, const char *name)
{
if (!switch_rtp_ready(rtp_session)) {
if (!switch_rtp_ready(rtp_session) || !rtp_session->jb) {
return SWITCH_STATUS_FALSE;
}