[farsight2/master] Use fs_candidate_new() in the rawudp test too
Olivier Crête
olivier.crete at collabora.co.uk
Tue Dec 23 15:22:13 PST 2008
---
tests/check/transmitter/rawudp.c | 20 ++++++--------------
1 files changed, 6 insertions(+), 14 deletions(-)
diff --git a/tests/check/transmitter/rawudp.c b/tests/check/transmitter/rawudp.c
index b0f84d8..6aee109 100644
--- a/tests/check/transmitter/rawudp.c
+++ b/tests/check/transmitter/rawudp.c
@@ -372,22 +372,14 @@ GST_START_TEST (test_rawudptransmitter_run_local_candidates)
memset (params, 0, sizeof (GParameter) * 1);
- candidate = g_new0 (FsCandidate, 1);
- candidate->candidate_id = g_strdup ("L1");
- candidate->component_id = FS_COMPONENT_RTP;
- candidate->ip = g_strdup ("127.0.0.1");
- candidate->port = RTP_PORT;
- candidate->proto = FS_NETWORK_PROTOCOL_UDP;
- candidate->type = FS_CANDIDATE_TYPE_HOST;
+ candidate = fs_candidate_new ("L1",
+ FS_COMPONENT_RTP, FS_CANDIDATE_TYPE_HOST,
+ FS_NETWORK_PROTOCOL_UDP, "127.0.0.1", RTP_PORT);
list = g_list_prepend (list, candidate);
- candidate = g_new0 (FsCandidate, 1);
- candidate->candidate_id = g_strdup ("L2");
- candidate->component_id = FS_COMPONENT_RTCP;
- candidate->ip = g_strdup ("127.0.0.1");
- candidate->port = RTCP_PORT;
- candidate->proto = FS_NETWORK_PROTOCOL_UDP;
- candidate->type = FS_CANDIDATE_TYPE_HOST;
+ candidate = fs_candidate_new ("L1",
+ FS_COMPONENT_RTCP, FS_CANDIDATE_TYPE_HOST,
+ FS_NETWORK_PROTOCOL_UDP, "127.0.0.1", RTCP_PORT);
list = g_list_prepend (list, candidate);
params[0].name = "preferred-local-candidates";
--
1.5.6.5
More information about the farsight-commits
mailing list