summaryrefslogtreecommitdiff
path: root/pjsip/src/test/transport_test.c
diff options
context:
space:
mode:
authorNanang Izzuddin <nanang@teluu.com>2009-04-28 19:38:43 +0000
committerNanang Izzuddin <nanang@teluu.com>2009-04-28 19:38:43 +0000
commit7a0ee1a7208ddfe8575d1f1179f66fda2fa99339 (patch)
treea21e4846fd4d08aa06d2f5424cf52042d6d1d9e1 /pjsip/src/test/transport_test.c
parentcd00a93db99d842d8fcadb60aeb20ba47b4b4165 (diff)
Ticket #706: Merged branch vs-reorg2 into trunk:
- Currently supported platforms are: Win32, WM6 std & pro, WM5 SP & PPC, WM2003 SP & PPC. - Added libpjproject into solution, this is a single 'combo' library that bundles all PJSIP libraries. - Cleaned up most of compile warnings, note that warning level of libgsmcodec has been reduced from 4 to 3. git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@2660 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip/src/test/transport_test.c')
-rw-r--r--pjsip/src/test/transport_test.c17
1 files changed, 14 insertions, 3 deletions
diff --git a/pjsip/src/test/transport_test.c b/pjsip/src/test/transport_test.c
index 9f19b68f..a17dca82 100644
--- a/pjsip/src/test/transport_test.c
+++ b/pjsip/src/test/transport_test.c
@@ -159,6 +159,8 @@ static pj_bool_t my_on_rx_response(pjsip_rx_data *rdata)
static void send_msg_callback(pjsip_send_state *stateless_data,
pj_ssize_t sent, pj_bool_t *cont)
{
+ PJ_UNUSED_ARG(stateless_data);
+
if (sent < 1) {
/* Obtain the error code. */
send_status = -sent;
@@ -184,6 +186,9 @@ int transport_send_recv_test( pjsip_transport_type_e tp_type,
pjsip_tx_data *tdata;
pj_time_val timeout;
+ PJ_UNUSED_ARG(tp_type);
+ PJ_UNUSED_ARG(ref_tp);
+
PJ_LOG(3,(THIS_FILE, " single message round-trip test..."));
/* Register out test module to receive the message (if necessary). */
@@ -490,6 +495,8 @@ static int rt_worker_thread(void *arg)
int i;
pj_time_val poll_delay = { 0, 10 };
+ PJ_UNUSED_ARG(arg);
+
/* Sleep to allow main threads to run. */
pj_thread_sleep(10);
@@ -520,6 +527,9 @@ int transport_rt_test( pjsip_transport_type_e tp_type,
unsigned total_sent;
unsigned total_recv;
+ PJ_UNUSED_ARG(tp_type);
+ PJ_UNUSED_ARG(ref_tp);
+
PJ_LOG(3,(THIS_FILE, " multithreaded round-trip test (%d threads)...",
THREADS));
PJ_LOG(3,(THIS_FILE, " this will take approx %d seconds, please wait..",
@@ -550,8 +560,9 @@ int transport_rt_test( pjsip_transport_type_e tp_type,
/* Initialize thread data. */
for (i=0; i<THREADS; ++i) {
char buf[1];
- pj_str_t str_id = { buf, 1 };
-
+ pj_str_t str_id;
+
+ pj_strset(&str_id, buf, 1);
pj_bzero(&rt_test_data[i], sizeof(rt_test_data[i]));
/* Init timer entry */
@@ -563,7 +574,7 @@ int transport_rt_test( pjsip_transport_type_e tp_type,
/* Generate Call-ID for each thread. */
rt_test_data[i].call_id.ptr = (char*) pj_pool_alloc(pool, rt_call_id.slen+1);
pj_strcpy(&rt_test_data[i].call_id, &rt_call_id);
- buf[0] = '0' + i;
+ buf[0] = '0' + (char)i;
pj_strcat(&rt_test_data[i].call_id, &str_id);
/* Init mutex. */