Browse code

pv: use macro to get port based on proto

Daniel-Constantin Mierla authored on 06/07/2021 09:08:00
Showing 1 changed files
... ...
@@ -704,7 +704,7 @@ int pv_get_nh_reply(struct sip_msg *msg, pv_param_t *param,
704 704
 		host = msg->via2->host;
705 705
 	}
706 706
 	if(port==0) {
707
-		port = (msg->via2->port)?msg->via2->port:SIP_PORT;
707
+		port = GET_SIP_PORT(msg->via2->port, msg->via2->proto);
708 708
 	}
709 709
 
710 710
 	switch(param->pvn.u.isname.name.n) {