exec_hf.c File Reference

#include <stdlib.h>
#include "../../parser/msg_parser.h"
#include "../../parser/parse_to.h"
#include "../../parser/parse_via.h"
#include "../../parser/parse_uri.h"
#include "../../mem/mem.h"
#include "../../dprint.h"
#include "../../md5utils.h"
#include "exec_hf.h"

Include dependency graph for exec_hf.c:

Go to the source code of this file.

Functions

static int append_fixed_vars (struct sip_msg *msg, struct hf_wrapper **list)
static int append_var (char *name, char *value, int len, struct hf_wrapper **list)
static int build_hf_struct (struct sip_msg *msg, struct hf_wrapper **list)
static int canonize_headername (str *orig, char **hname, int *hlen)
static int compacthdr_type2str (hdr_types_t type, char **hname, int *hlen)
static int create_vars (struct hf_wrapper *list, int offset)
static int insert_hf (struct hf_wrapper **list, struct hdr_field *hf)
static int print_av_var (struct hf_wrapper *w)
static int print_hf_var (struct hf_wrapper *w, int offset)
static int print_var (struct hf_wrapper *w, int offset)
static void release_hf_struct (struct hf_wrapper *list)
static void release_vars (struct hf_wrapper *list)
environment_treplace_env (struct hf_wrapper *list)
environment_tset_env (struct sip_msg *msg)
void unset_env (environment_t *backup_env)

Variables

unsigned int setvars = 1


Function Documentation

static int append_fixed_vars ( struct sip_msg msg,
struct hf_wrapper **  list 
) [static]

static int append_var ( char *  name,
char *  value,
int  len,
struct hf_wrapper **  list 
) [static]

static int build_hf_struct ( struct sip_msg msg,
struct hf_wrapper **  list 
) [static]

Definition at line 302 of file exec_hf.c.

References sip_msg::headers, insert_hf(), LM_ERR, hdr_field::next, and release_hf_struct().

Referenced by set_env().

static int canonize_headername ( str orig,
char **  hname,
int *  hlen 
) [static]

Definition at line 165 of file exec_hf.c.

References ESCAPE, HFN_SYMBOL, HNV_UNRESERVED, _str::len, LM_ERR, pkg_malloc, _str::s, and UNRESERVED_MARK.

Referenced by print_hf_var().

static int compacthdr_type2str ( hdr_types_t  type,
char **  hname,
int *  hlen 
) [static]

static int create_vars ( struct hf_wrapper list,
int  offset 
) [static]

Definition at line 323 of file exec_hf.c.

References LM_ERR, hf_wrapper::next_other, and print_var().

Referenced by set_env().

static int insert_hf ( struct hf_wrapper **  list,
struct hdr_field hf 
) [static]

static int print_av_var ( struct hf_wrapper w  )  [static]

static int print_hf_var ( struct hf_wrapper w,
int  offset 
) [static]

static int print_var ( struct hf_wrapper w,
int  offset 
) [static]

Definition at line 277 of file exec_hf.c.

References LM_CRIT, print_av_var(), print_hf_var(), hf_wrapper::var_type, W_AV, and W_HF.

Referenced by create_vars().

static void release_hf_struct ( struct hf_wrapper list  )  [static]

Definition at line 95 of file exec_hf.c.

References hf_wrapper::next_other, hf_wrapper::next_same, and pkg_free.

Referenced by build_hf_struct(), and set_env().

static void release_vars ( struct hf_wrapper list  )  [static]

Definition at line 290 of file exec_hf.c.

References hf_wrapper::envvar, hf_wrapper::next_other, and pkg_free.

Referenced by set_env().

environment_t* replace_env ( struct hf_wrapper list  ) 

Definition at line 341 of file exec_hf.c.

References env::env, environ, hf_wrapper::envvar, LM_ERR, hf_wrapper::next_other, env::old_cnt, and pkg_malloc.

Referenced by set_env().

environment_t* set_env ( struct sip_msg msg  ) 

void unset_env ( environment_t backup_env  ) 

Definition at line 385 of file exec_hf.c.

References env::env, environ, env::old_cnt, and pkg_free.

Referenced by w_exec_avp(), w_exec_dset(), and w_exec_msg().


Variable Documentation

unsigned int setvars = 1

Definition at line 55 of file exec_hf.c.

Referenced by w_exec_avp(), w_exec_dset(), and w_exec_msg().


Generated on Wed May 23 06:01:03 2012 for Kamailio - The Open Source SIP Server by  doxygen 1.5.6