aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@netfilter.org>2012-08-06 20:20:57 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2012-08-06 21:04:25 +0200
commit7a01104b881153d1cbd73b7dd98149b16d53ee69 (patch)
treef06980104dfa48ddd23c445bf3e515cdb7fdc563 /src
parent72a0aae500de36ef3fa528a9ce2e32a8ddde5080 (diff)
osmux: add OSMUX_MAX_CONCURRENT_CALLS which is 8
Instead of harcoding the number all around the code.
Diffstat (limited to 'src')
-rw-r--r--src/osmux.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/osmux.c b/src/osmux.c
index ad18c36..5916edc 100644
--- a/src/osmux.c
+++ b/src/osmux.c
@@ -385,7 +385,7 @@ void osmux_xfrm_input_init(struct osmux_in_handle *h)
batch->timer.cb = osmux_batch_timer_expired;
batch->timer.data = h;
- for (i=0; i<8; i++)
+ for (i=0; i<OSMUX_MAX_CONCURRENT_CALLS; i++)
batch->ccid[i] = -1;
h->data = (void *)batch;
@@ -475,7 +475,7 @@ void osmux_xfrm_input_register_ccid(struct osmux_in_handle *h, uint32_t ssrc)
struct osmux_batch *batch = (struct osmux_batch *)h->data;;
int i, found = 0;
- for (i=0; i<8; i++) {
+ for (i=0; i<OSMUX_MAX_CONCURRENT_CALLS; i++) {
if (batch->ccid[i] == ssrc)
continue;
if (batch->ccid[i] < 0) {
@@ -498,7 +498,7 @@ int osmux_xfrm_input_get_ccid(struct osmux_in_handle *h, uint32_t ssrc)
struct osmux_batch *batch = (struct osmux_batch *)h->data;;
int i, found = 0;
- for (i=0; i<8; i++) {
+ for (i=0; i<OSMUX_MAX_CONCURRENT_CALLS; i++) {
if (batch->ccid[i] == ssrc) {
found = 1;
break;
@@ -512,7 +512,7 @@ void osmux_xfrm_output_init(struct osmux_out_handle *h)
{
int i;
- for (i=0; i<8; i++) {
+ for (i=0; i<OSMUX_MAX_CONCURRENT_CALLS; i++) {
h->rtp_seq[i] = (uint16_t)random();
h->rtp_timestamp[i] = (uint32_t)random();
}