[farsight2/master] Verify that component_id is not 0 in add_remote_candidate
Olivier Crête
olivier.crete at collabora.co.uk
Tue Dec 23 15:19:41 PST 2008
---
transmitters/rawudp/fs-rawudp-stream-transmitter.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/transmitters/rawudp/fs-rawudp-stream-transmitter.c b/transmitters/rawudp/fs-rawudp-stream-transmitter.c
index 76c277b..86ad094 100644
--- a/transmitters/rawudp/fs-rawudp-stream-transmitter.c
+++ b/transmitters/rawudp/fs-rawudp-stream-transmitter.c
@@ -610,9 +610,10 @@ fs_rawudp_stream_transmitter_add_remote_candidate (
return FALSE;
}
- if (candidate->component_id > self->priv->transmitter->components) {
+ if (candidate->component_id == 0 ||
+ candidate->component_id > self->priv->transmitter->components) {
g_set_error (error, FS_ERROR, FS_ERROR_INVALID_ARGUMENTS,
- "The candidate passed has has an invalid component id %u (> %u)",
+ "The candidate passed has has an invalid component id %u (not in [0,%u])",
candidate->component_id, self->priv->transmitter->components);
return FALSE;
}
--
1.5.6.5
More information about the farsight-commits
mailing list