summaryrefslogtreecommitdiff
path: root/pjsip
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2006-07-23 14:38:49 +0000
committerBenny Prijono <bennylp@teluu.com>2006-07-23 14:38:49 +0000
commit506a01d84b9577c45ec6f95be15345017c96b809 (patch)
tree6597111b01ad386a463d90d27aa7973494a394db /pjsip
parent0e925222f36d4f3d34a88cbe149f8f761d47ac26 (diff)
Added 64bit Linux target (x86_64), also fixed compilation warnings when compiling for this target
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@624 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip')
-rw-r--r--pjsip/src/pjsip/sip_transport_udp.c4
-rw-r--r--pjsip/src/pjsip/sip_ua_layer.c20
-rw-r--r--pjsip/src/test-pjsip/msg_test.c6
-rw-r--r--pjsip/src/test-pjsip/transport_loop_test.c2
-rw-r--r--pjsip/src/test-pjsip/transport_tcp_test.c2
-rw-r--r--pjsip/src/test-pjsip/transport_test.c4
-rw-r--r--pjsip/src/test-pjsip/transport_udp_test.c2
-rw-r--r--pjsip/src/test-pjsip/uri_test.c6
8 files changed, 26 insertions, 20 deletions
diff --git a/pjsip/src/pjsip/sip_transport_udp.c b/pjsip/src/pjsip/sip_transport_udp.c
index 5bcd454d..d0c6c307 100644
--- a/pjsip/src/pjsip/sip_transport_udp.c
+++ b/pjsip/src/pjsip/sip_transport_udp.c
@@ -86,7 +86,7 @@ static void init_rdata(struct udp_transport *tp, unsigned rdata_index,
/* Init tp_info part. */
rdata->tp_info.pool = pool;
rdata->tp_info.transport = &tp->base;
- rdata->tp_info.tp_data = (void*) rdata_index;
+ rdata->tp_info.tp_data = (void*)(long)rdata_index;
rdata->tp_info.op_key.rdata = rdata;
pj_ioqueue_op_key_init(&rdata->tp_info.op_key.op_key,
sizeof(pj_ioqueue_op_key_t));
@@ -190,7 +190,7 @@ static void udp_on_read_complete( pj_ioqueue_key_t *key,
unsigned rdata_index;
rdata_tp = (struct udp_transport*)rdata->tp_info.transport;
- rdata_index = (unsigned)rdata->tp_info.tp_data;
+ rdata_index = (unsigned)(unsigned long)rdata->tp_info.tp_data;
pj_pool_reset(rdata_pool);
init_rdata(rdata_tp, rdata_index, rdata_pool, &rdata);
diff --git a/pjsip/src/pjsip/sip_ua_layer.c b/pjsip/src/pjsip/sip_ua_layer.c
index a38825eb..2010dace 100644
--- a/pjsip/src/pjsip/sip_ua_layer.c
+++ b/pjsip/src/pjsip/sip_ua_layer.c
@@ -539,13 +539,19 @@ static pj_bool_t mod_ua_on_rx_request(pjsip_rx_data *rdata)
/* Not found. Mulfunction UAC? */
pj_mutex_unlock(mod_ua.mutex);
- PJ_LOG(5,(THIS_FILE,
- "Unable to find dialog for %s, answering with 481",
- pjsip_rx_data_get_info(rdata)));
-
- pjsip_endpt_respond_stateless(mod_ua.endpt, rdata,
- PJSIP_SC_CALL_TSX_DOES_NOT_EXIST,
- NULL, NULL, NULL);
+ if (rdata->msg_info.msg->line.req.method.id != PJSIP_ACK_METHOD) {
+ PJ_LOG(5,(THIS_FILE,
+ "Unable to find dialog for %s, answering with 481",
+ pjsip_rx_data_get_info(rdata)));
+
+ pjsip_endpt_respond_stateless(mod_ua.endpt, rdata,
+ PJSIP_SC_CALL_TSX_DOES_NOT_EXIST,
+ NULL, NULL, NULL);
+ } else {
+ PJ_LOG(5,(THIS_FILE,
+ "Unable to find dialog for %s",
+ pjsip_rx_data_get_info(rdata)));
+ }
return PJ_TRUE;
}
diff --git a/pjsip/src/test-pjsip/msg_test.c b/pjsip/src/test-pjsip/msg_test.c
index d0039047..6954f015 100644
--- a/pjsip/src/test-pjsip/msg_test.c
+++ b/pjsip/src/test-pjsip/msg_test.c
@@ -818,7 +818,7 @@ int msg_test(void)
"can be pre-parse by <tt>pjsip_find_msg()</tt> "
"per second (tested with %d message sets with "
"average message length of "
- "%d bytes)", PJ_ARRAY_SIZE(test_array), avg_len);
+ "%d bytes)", (int)PJ_ARRAY_SIZE(test_array), avg_len);
report_ival("msg-detect-per-sec", max, "msg/sec", desc);
/* Print maximum parse/sec */
@@ -831,7 +831,7 @@ int msg_test(void)
"can be <b>parsed</b> by <tt>pjsip_parse_msg()</tt> "
"per second (tested with %d message sets with "
"average message length of "
- "%d bytes)", PJ_ARRAY_SIZE(test_array), avg_len);
+ "%d bytes)", (int)PJ_ARRAY_SIZE(test_array), avg_len);
report_ival("msg-parse-per-sec", max, "msg/sec", desc);
/* Msg parsing bandwidth */
@@ -851,7 +851,7 @@ int msg_test(void)
"can be <b>printed</b> by <tt>pjsip_msg_print()</tt>"
" per second (tested with %d message sets with "
"average message length of "
- "%d bytes)", PJ_ARRAY_SIZE(test_array), avg_len);
+ "%d bytes)", (int)PJ_ARRAY_SIZE(test_array), avg_len);
report_ival("msg-print-per-sec", max, "msg/sec", desc);
diff --git a/pjsip/src/test-pjsip/transport_loop_test.c b/pjsip/src/test-pjsip/transport_loop_test.c
index 3e378832..c2c122ec 100644
--- a/pjsip/src/test-pjsip/transport_loop_test.c
+++ b/pjsip/src/test-pjsip/transport_loop_test.c
@@ -31,7 +31,7 @@ static int datagram_loop_test()
pj_sockaddr_in addr;
pj_status_t status;
long ref_cnt;
- unsigned rtt[LOOP], min_rtt;
+ int rtt[LOOP], min_rtt;
PJ_LOG(3,(THIS_FILE, "testing datagram loop transport"));
diff --git a/pjsip/src/test-pjsip/transport_tcp_test.c b/pjsip/src/test-pjsip/transport_tcp_test.c
index 70f1bc92..c3578ee6 100644
--- a/pjsip/src/test-pjsip/transport_tcp_test.c
+++ b/pjsip/src/test-pjsip/transport_tcp_test.c
@@ -35,7 +35,7 @@ int transport_tcp_test(void)
pj_sockaddr_in rem_addr;
pj_status_t status;
char url[64];
- unsigned rtt[SEND_RECV_LOOP], min_rtt;
+ int rtt[SEND_RECV_LOOP], min_rtt;
int i, pkt_lost;
/* Start TCP listener on arbitrary port. */
diff --git a/pjsip/src/test-pjsip/transport_test.c b/pjsip/src/test-pjsip/transport_test.c
index 2d84efea..e5baa040 100644
--- a/pjsip/src/test-pjsip/transport_test.c
+++ b/pjsip/src/test-pjsip/transport_test.c
@@ -489,7 +489,7 @@ static void rt_tx_timer( pj_timer_heap_t *timer_heap,
static int rt_worker_thread(void *arg)
{
- int i, thread_id = (int)arg;
+ int i, thread_id = (int)(long)arg;
pj_time_val poll_delay = { 0, 10 };
/* Sleep to allow main threads to run. */
@@ -576,7 +576,7 @@ int transport_rt_test( pjsip_transport_type_e tp_type,
}
/* Create thread, suspended. */
- status = pj_thread_create(pool, "rttest%p", &rt_worker_thread, (void*)i, 0,
+ status = pj_thread_create(pool, "rttest%p", &rt_worker_thread, (void*)(long)i, 0,
PJ_THREAD_SUSPENDED, &rt_test_data[i].thread);
if (status != PJ_SUCCESS) {
app_perror(" error: unable to create thread", status);
diff --git a/pjsip/src/test-pjsip/transport_udp_test.c b/pjsip/src/test-pjsip/transport_udp_test.c
index 34bb02c4..d24d862e 100644
--- a/pjsip/src/test-pjsip/transport_udp_test.c
+++ b/pjsip/src/test-pjsip/transport_udp_test.c
@@ -34,7 +34,7 @@ int transport_udp_test(void)
pj_sockaddr_in addr, rem_addr;
pj_str_t s;
pj_status_t status;
- unsigned rtt[SEND_RECV_LOOP], min_rtt;
+ int rtt[SEND_RECV_LOOP], min_rtt;
int i, pkt_lost;
pj_sockaddr_in_init(&addr, NULL, TEST_UDP_PORT);
diff --git a/pjsip/src/test-pjsip/uri_test.c b/pjsip/src/test-pjsip/uri_test.c
index a0fc1fb2..da3c1833 100644
--- a/pjsip/src/test-pjsip/uri_test.c
+++ b/pjsip/src/test-pjsip/uri_test.c
@@ -955,7 +955,7 @@ int uri_test(void)
"<tt>pjsip_parse_uri()</tt> per second "
"(tested with %d URI set, with average length of "
"%d chars)",
- PJ_ARRAY_SIZE(uri_test_array), avg_len);
+ (int)PJ_ARRAY_SIZE(uri_test_array), avg_len);
report_ival("uri-parse-per-sec", max, "URI/sec", desc);
@@ -975,7 +975,7 @@ int uri_test(void)
"<tt>pjsip_uri_print()</tt> per second "
"(tested with %d URI set, with average length of "
"%d chars)",
- PJ_ARRAY_SIZE(uri_test_array), avg_len);
+ (int)PJ_ARRAY_SIZE(uri_test_array), avg_len);
report_ival("uri-print-per-sec", max, "URI/sec", desc);
@@ -989,7 +989,7 @@ int uri_test(void)
"<tt>pjsip_uri_cmp()</tt> per second "
"(tested with %d URI set, with average length of "
"%d chars)",
- PJ_ARRAY_SIZE(uri_test_array), avg_len);
+ (int)PJ_ARRAY_SIZE(uri_test_array), avg_len);
report_ival("uri-cmp-per-sec", max, "URI/sec", desc);