Revision 4fa7a2cf

View differences:

plugins/janus_sip.c
327 327
	janus_sip_account account;
328 328
	janus_sip_call_status status;
329 329
	janus_sip_media media;
330
	sdp_parser_t *raw_media;
330 331
	char *transaction;
331 332
	char *callee;
332 333
	janus_recorder *arc;		/* The Janus recorder instance for this user's audio, if enabled */
......
2276 2277
			}
2277 2278
			if(session->stack->s_nh_i != NULL) {
2278 2279
				if(session->stack->s_nh_i == nh) {
2279
					/* re-INVITE, we don't support those. */
2280
					nua_respond(nh, 488, sip_status_phrase(488), TAG_END());
2280
					if (sdp_session_cmp(sdp_session(session->raw_media), sdp_session(parser)) == 0) {
2281
						/* re-INVITE that is basically a session-refresh (no media-change needed), accept. */
2282
						nua_respond(nh, 200, sip_status_phrase(200), TAG_END());
2283
					} else {
2284
						/* re-INVITE, we don't support those. */
2285
						nua_respond(nh, 488, sip_status_phrase(488), TAG_END());
2286
					}
2281 2287
				} else if(session->status >= janus_sip_call_status_inviting) {
2282 2288
					/* Busy with another call */
2283 2289
					JANUS_LOG(LOG_VERB, "\tAlready in a call (busy, status=%s)\n", janus_sip_call_status_string(session->status));
......
2464 2470
				JANUS_LOG(LOG_VERB, "Detected video codec: %d (%s)\n", session->media.video_pt, session->media.video_pt_name);
2465 2471
			}
2466 2472
			session->media.ready = 1;	/* FIXME Maybe we need a better way to signal this */
2473
			session->raw_media = parser;
2467 2474
			GError *error = NULL;
2468 2475
			g_thread_try_new("janus rtp handler", janus_sip_relay_thread, session, &error);
2469 2476
			if(error != NULL) {

Also available in: Unified diff