mirror of
				https://github.com/asterisk/asterisk.git
				synced 2025-10-31 02:37:10 +00:00 
			
		
		
		
	res_pjsip: Add utils for checking media types
Added two new functions to assist checking media types... * ast_sip_are_media_types_equal compares two pjsip_media_types. * ast_sip_is_media_type_in tests if one media type is in a list of others. Added static definitions for commonly used media types to res_pjsip.h. Changed several modules to use the new functions and static definitions. ASTERISK_29813 (not ready to close) Change-Id: Ief77675235bd3bf00a6b095d4673fd878d0801b9
This commit is contained in:
		
				
					committed by
					
						 Joshua Colp
						Joshua Colp
					
				
			
			
				
	
			
			
			
						parent
						
							1ce57621de
						
					
				
				
					commit
					a611c07dd4
				
			| @@ -2317,9 +2317,8 @@ static int video_info_incoming_request(struct ast_sip_session *session, struct p | ||||
| 	pjsip_tx_data *tdata; | ||||
|  | ||||
| 	if (!session->channel | ||||
| 		|| !ast_sip_is_content_type(&rdata->msg_info.msg->body->content_type, | ||||
| 			"application", | ||||
| 			"media_control+xml")) { | ||||
| 		|| !ast_sip_are_media_types_equal(&rdata->msg_info.msg->body->content_type, | ||||
| 			&pjsip_media_type_application_media_control_xml)) { | ||||
| 		return 0; | ||||
| 	} | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user