浏览代码

Kamailio compatibility: Privacy header field name parser

This patch extendes the tm module with support for the Privacy header
field which are now parsed by the core, this patch teaches tm how to
ignore them.
Jan Janak 16 年之前
父节点
当前提交
f4e8001524
共有 1 个文件被更改,包括 6 次插入0 次删除
  1. 6 0
      modules/tm/sip_msg.c

+ 6 - 0
modules/tm/sip_msg.c

@@ -490,6 +490,7 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg, int *sip_msg_len )
 		case HDR_PPI_T:
 		case HDR_PAI_T:
 		case HDR_PATH_T:
+		case HDR_PRIVACY_T:
 			/* we ignore them for now even if they have something parsed*/
 			break;
 		}/*switch*/
@@ -893,6 +894,11 @@ struct sip_msg*  sip_msg_cloner( struct sip_msg *org_msg, int *sip_msg_len )
 				new_msg->path = new_hdr;
 			}
 			break;
+		case HDR_PRIVACY_T:
+			if (!HOOK_SET(privacy)) {
+				new_msg->privacy = new_hdr;
+			}
+			break;
 		}/*switch*/
 
 		if ( last_hdr )