Index: pjproject/trunk/pjmedia/src/pjmedia/conference.c
===================================================================
--- pjproject/trunk/pjmedia/src/pjmedia/conference.c	(revision 1227)
+++ pjproject/trunk/pjmedia/src/pjmedia/conference.c	(revision 1266)
@@ -240,5 +240,5 @@
 
     /* Create port. */
-    conf_port = pj_pool_zalloc(pool, sizeof(struct conf_port));
+    conf_port = PJ_POOL_ZALLOC_T(pool, struct conf_port);
     PJ_ASSERT_RETURN(conf_port, PJ_ENOMEM);
 
@@ -255,5 +255,6 @@
 
     /* Create transmit flag array */
-    conf_port->listener_slots = pj_pool_zalloc(pool, 
+    conf_port->listener_slots = (SLOT_TYPE*)
+				pj_pool_zalloc(pool, 
 					  conf->max_ports * sizeof(SLOT_TYPE));
     PJ_ASSERT_RETURN(conf_port->listener_slots, PJ_ENOMEM);
@@ -336,5 +337,6 @@
 					   conf->clock_rate);
 	conf_port->rx_buf_count = 0;
-	conf_port->rx_buf = pj_pool_alloc(pool, conf_port->rx_buf_cap *
+	conf_port->rx_buf = (pj_int16_t*)
+			    pj_pool_alloc(pool, conf_port->rx_buf_cap *
 						sizeof(conf_port->rx_buf[0]));
 	PJ_ASSERT_RETURN(conf_port->rx_buf, PJ_ENOMEM);
@@ -343,5 +345,6 @@
 	conf_port->tx_buf_cap = conf_port->rx_buf_cap;
 	conf_port->tx_buf_count = 0;
-	conf_port->tx_buf = pj_pool_alloc(pool, conf_port->tx_buf_cap *
+	conf_port->tx_buf = (pj_int16_t*)
+			    pj_pool_alloc(pool, conf_port->tx_buf_cap *
 						sizeof(conf_port->tx_buf[0]));
 	PJ_ASSERT_RETURN(conf_port->tx_buf, PJ_ENOMEM);
@@ -350,5 +353,6 @@
 
     /* Create mix buffer. */
-    conf_port->mix_buf = pj_pool_zalloc(pool, conf->samples_per_frame *
+    conf_port->mix_buf = (pj_uint32_t*)
+			 pj_pool_zalloc(pool, conf->samples_per_frame *
 					      sizeof(conf_port->mix_buf[0]));
     PJ_ASSERT_RETURN(conf_port->mix_buf, PJ_ENOMEM);
@@ -381,5 +385,6 @@
     /* Passive port has rx buffers. */
     for (i=0; i<RX_BUF_COUNT; ++i) {
-	conf_port->snd_buf[i] = pj_pool_zalloc(pool, conf->samples_per_frame *
+	conf_port->snd_buf[i] = (pj_int16_t*)
+				pj_pool_zalloc(pool, conf->samples_per_frame *
 					      sizeof(conf_port->snd_buf[0][0]));
 	if (conf_port->snd_buf[i] == NULL) {
@@ -487,8 +492,9 @@
 
     /* Create and init conf structure. */
-    conf = pj_pool_zalloc(pool, sizeof(pjmedia_conf));
+    conf = PJ_POOL_ZALLOC_T(pool, pjmedia_conf);
     PJ_ASSERT_RETURN(conf, PJ_ENOMEM);
 
-    conf->ports = pj_pool_zalloc(pool, max_ports*sizeof(void*));
+    conf->ports = (struct conf_port**) 
+		  pj_pool_zalloc(pool, max_ports*sizeof(void*));
     PJ_ASSERT_RETURN(conf->ports, PJ_ENOMEM);
 
@@ -502,5 +508,5 @@
     
     /* Create and initialize the master port interface. */
-    conf->master_port = pj_pool_zalloc(pool, sizeof(pjmedia_port));
+    conf->master_port = PJ_POOL_ZALLOC_T(pool, pjmedia_port);
     PJ_ASSERT_RETURN(conf->master_port, PJ_ENOMEM);
     
@@ -523,5 +529,6 @@
 
     /* Create temporary buffer. */
-    conf->uns_buf = pj_pool_zalloc(pool, samples_per_frame *
+    conf->uns_buf = (pj_uint16_t*)
+		    pj_pool_zalloc(pool, samples_per_frame *
 					 sizeof(conf->uns_buf[0]));
 
@@ -598,5 +605,5 @@
 static pj_status_t destroy_port(pjmedia_port *this_port)
 {
-    pjmedia_conf *conf = this_port->port_data.pdata;
+    pjmedia_conf *conf = (pjmedia_conf*) this_port->port_data.pdata;
     return pjmedia_conf_destroy(conf);
 }
@@ -626,5 +633,5 @@
 						const pj_str_t *name)
 {
-    int len;
+    unsigned len;
 
     /* Sanity check. */
@@ -764,10 +771,10 @@
 	name = &tmp;
 
-	tmp.ptr = pj_pool_alloc(pool, 32);
+	tmp.ptr = (char*) pj_pool_alloc(pool, 32);
 	tmp.slen = pj_ansi_snprintf(tmp.ptr, 32, "ConfPort#%d", index);
     }
 
     /* Create and initialize the media port structure. */
-    port = pj_pool_zalloc(pool, sizeof(pjmedia_port));
+    port = PJ_POOL_ZALLOC_T(pool, pjmedia_port);
     PJ_ASSERT_RETURN(port, PJ_ENOMEM);
     
@@ -1601,5 +1608,5 @@
 			     pjmedia_frame *frame)
 {
-    pjmedia_conf *conf = this_port->port_data.pdata;
+    pjmedia_conf *conf = (pjmedia_conf*) this_port->port_data.pdata;
     pjmedia_frame_type speaker_frame_type = PJMEDIA_FRAME_TYPE_NONE;
     unsigned ci, cj, i, j;
@@ -1677,5 +1684,6 @@
 
 	    snd_buf = conf_port->snd_buf[conf_port->snd_read_pos];
-	    pjmedia_copy_samples(frame->buf, snd_buf, conf->samples_per_frame);
+	    pjmedia_copy_samples((pj_int16_t*)frame->buf, snd_buf, 
+				 conf->samples_per_frame);
 	    conf_port->snd_read_pos = (conf_port->snd_read_pos+1) % RX_BUF_COUNT;
 
@@ -1685,5 +1693,5 @@
 	    pjmedia_frame_type frame_type;
 
-	    status = read_port(conf, conf_port, frame->buf, 
+	    status = read_port(conf, conf_port, (pj_int16_t*)frame->buf, 
 			       conf->samples_per_frame, &frame_type);
 	    
@@ -1711,5 +1719,5 @@
 	 */
 	if (conf_port->rx_adj_level != NORMAL_LEVEL) {
-	    pj_int16_t *input = frame->buf;
+	    pj_int16_t *input = (pj_int16_t*) frame->buf;
 	    pj_int32_t adj = conf_port->rx_adj_level;
 
@@ -1739,5 +1747,5 @@
 
 	} else {
-	    level = pjmedia_calc_avg_signal(frame->buf, 
+	    level = pjmedia_calc_avg_signal((pj_int16_t*) frame->buf, 
 					    conf->samples_per_frame);
 	}
@@ -1800,5 +1808,6 @@
 	    if (listener->transmitter_cnt == 1) {
 		pjmedia_copy_samples((pj_int16_t*)mix_buf, 
-				     frame->buf, conf->samples_per_frame);
+				     (const pj_int16_t*)frame->buf, 
+				     conf->samples_per_frame);
 		listener->src_level = level;
 	    } else {
@@ -1857,8 +1866,9 @@
 			   conf->samples_per_frame));
 
-	pjmedia_copy_samples( frame->buf, (pj_int16_t*)conf->ports[0]->mix_buf, 
+	pjmedia_copy_samples( (pj_int16_t*)frame->buf, 
+			      (const pj_int16_t*)conf->ports[0]->mix_buf, 
 			      conf->samples_per_frame);
     } else {
-	pjmedia_zero_samples( frame->buf, conf->samples_per_frame ); 
+	pjmedia_zero_samples((pj_int16_t*)frame->buf, conf->samples_per_frame); 
     }
 
@@ -1898,7 +1908,7 @@
 			     const pjmedia_frame *frame)
 {
-    pjmedia_conf *conf = this_port->port_data.pdata;
+    pjmedia_conf *conf = (pjmedia_conf*) this_port->port_data.pdata;
     struct conf_port *port = conf->ports[this_port->port_data.ldata];
-    const pj_int16_t *input = frame->buf;
+    const pj_int16_t *input = (const pj_int16_t*) frame->buf;
     pj_int16_t *target_snd_buf;
 
