parser/parse_from.h
d440f863
 /*
c32feee5
  * Copyright (C) 2001-2003 FhG Fokus
7dd0b342
  *
07ca8c05
  * This file is part of Kamailio, a free SIP server.
7dd0b342
  *
07ca8c05
  * Kamailio is free software; you can redistribute it and/or modify
7dd0b342
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 2 of the License, or
  * (at your option) any later version
  *
07ca8c05
  * Kamailio is distributed in the hope that it will be useful,
7dd0b342
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  * GNU General Public License for more details.
  *
  * You should have received a copy of the GNU General Public License 
  * along with this program; if not, write to the Free Software 
9e1ff448
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
d440f863
  */
 
7b7456b0
 /*! \file
  * \brief Parser :: SIP From header parsing
  *
  * \ingroup parser
  */
 
7dd0b342
 
ea9d260c
 #ifndef _PARSE_FROM_H
 #define _PARSE_FROM_H
 
08739917
 #include "parse_to.h"
ea9d260c
 #include "msg_parser.h"
d440f863
 
1d98277a
 
 /* casting macro for accessing From body */
 #define get_from(p_msg)  ((struct to_body*)(p_msg)->from->parsed)
 
3b823d28
 #define free_from(_to_body_)  free_to(_to_body_)
 
8016597d
 #define GET_FROM_PURI(p_msg) \
 	(&((struct to_body*)(p_msg)->from->parsed)->parsed_uri)
1d98277a
 
d440f863
 /*
4b02ed34
  * From header field parser
d440f863
  */
ea9d260c
 int parse_from_header( struct sip_msg *msg);
d440f863
 
f7f5ca4f
 sip_uri_t *parse_from_uri(sip_msg_t *msg);
 
d440f863
 #endif