comparison libpurple/media/media.c @ 29173:983af0970bb2

Transfer setting Farsight 2's remote candidates to the Fs2 media backend.
author maiku@pidgin.im
date Mon, 26 Oct 2009 22:14:25 +0000
parents f600903f7811
children d9d0674dfbb3
comparison
equal deleted inserted replaced
29172:f600903f7811 29173:983af0970bb2
1529 const gchar *participant, 1529 const gchar *participant,
1530 GList *remote_candidates) 1530 GList *remote_candidates)
1531 { 1531 {
1532 #ifdef USE_VV 1532 #ifdef USE_VV
1533 PurpleMediaStream *stream; 1533 PurpleMediaStream *stream;
1534 GError *err = NULL;
1535 1534
1536 g_return_if_fail(PURPLE_IS_MEDIA(media)); 1535 g_return_if_fail(PURPLE_IS_MEDIA(media));
1537 stream = purple_media_get_stream(media, sess_id, participant); 1536 stream = purple_media_get_stream(media, sess_id, participant);
1538 1537
1539 if (stream == NULL) { 1538 if (stream == NULL) {
1547 1546
1548 stream->remote_candidates = g_list_concat(stream->remote_candidates, 1547 stream->remote_candidates = g_list_concat(stream->remote_candidates,
1549 purple_media_candidate_list_copy(remote_candidates)); 1548 purple_media_candidate_list_copy(remote_candidates));
1550 1549
1551 if (stream->accepted == TRUE) { 1550 if (stream->accepted == TRUE) {
1552 GList *candidates = purple_media_candidate_list_to_fs( 1551 purple_media_backend_add_remote_candidates(
1553 stream->remote_candidates); 1552 media->priv->backend, sess_id, participant,
1554 fs_stream_set_remote_candidates(stream->stream, 1553 remote_candidates);
1555 candidates, &err);
1556 fs_candidate_list_destroy(candidates);
1557
1558 if (err) {
1559 purple_debug_error("media", "Error adding remote"
1560 " candidates: %s\n", err->message);
1561 g_error_free(err);
1562 }
1563 } 1554 }
1564 #endif 1555 #endif
1565 } 1556 }
1566 1557
1567 #if 0 1558 #if 0