osip_port.c File Reference

Operation system dependent includes, definitions and functions in oSIP library. More...

#include <stdlib.h>
#include <stdio.h>
#include <stdarg.h>
#include "osip_port.h"
#include <time.h>
#include <sys/time.h>

Include dependency graph for osip_port.c:

Go to the source code of this file.

Functions

unsigned int osip_build_random_number ()
int osip_atoi (const char *number)
char * osip_strncpy (char *dest, const char *src, size_t length)
char * __osip_sdp_append_string (char *string, size_t size, char *cur, char *string_osip_to_append)
void osip_usleep (int useconds)
char * osip_strdup (const char *ch)
char * osip_strdup_without_quote (const char *ch)
int osip_tolower (char *word)
int osip_strcasecmp (const char *s1, const char *s2)
int osip_strncasecmp (const char *s1, const char *s2, size_t len)
int osip_clrspace (char *word)
int __osip_set_next_token (char **dest, char *buf, int end_separator, char **next)
char * __osip_quote_find (const char *qstring)
char * osip_enquote (const char *s)
void osip_dequote (char *s)
void osip_trace_initialize_func (osip_trace_level_t level, osip_trace_func_t *func)
void osip_trace_initialize_syslog (osip_trace_level_t level, char *ident)
void osip_trace_initialize (osip_trace_level_t level, FILE *file)
void osip_trace_enable_level (osip_trace_level_t level)
void osip_trace_disable_level (osip_trace_level_t level)
int osip_is_trace_level_activate (osip_trace_level_t level)
int osip_trace (char *fi, int li, osip_trace_level_t level, FILE *f, char *chfr,...)
void osip_set_allocators (osip_malloc_func_t *malloc_func, osip_realloc_func_t *realloc_func, osip_free_func_t *free_func)
unsigned long osip_hash (const char *str)
char * osip_str_append (char *dst, const char *src)
char * osip_strn_append (char *dst, const char *src, size_t len)
char * osip_clrncpy (char *dst, const char *src, size_t len)

Variables

FILE * logfile = NULL
int tracing_table [END_TRACE_LEVEL]
static int use_syslog = 0
static osip_trace_func_ttrace_func = 0
static unsigned int random_seed_set = 0
osip_malloc_func_tosip_malloc_func = 0
osip_realloc_func_tosip_realloc_func = 0
osip_free_func_tosip_free_func = 0


Detailed Description

Operation system dependent includes, definitions and functions in oSIP library.

Author
peltotal
Date
2006/11/07 19:36:20
Revision
1.3

The oSIP library implements the Session Initiation Protocol (SIP -rfc3261-) Copyright (C) 2001,2002,2003,2004 Aymeric MOIZARD jack@atosc.org

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

Definition in file osip_port.c.


Function Documentation

char* __osip_quote_find ( const char *  qstring  ) 

Definition at line 501 of file osip_port.c.

char* __osip_sdp_append_string ( char *  string,
size_t  size,
char *  cur,
char *  string_osip_to_append 
)

Definition at line 242 of file osip_port.c.

References osip_realloc, and osip_strncpy().

Referenced by sdp_append_attribute(), sdp_append_bandwidth(), sdp_append_connection(), sdp_append_key(), sdp_append_media(), sdp_append_time_descr(), and sdp_message_to_str().

Here is the call graph for this function:

Here is the caller graph for this function:

int __osip_set_next_token ( char **  dest,
char *  buf,
int  end_separator,
char **  next 
)

Definition at line 438 of file osip_port.c.

References osip_malloc, and osip_strncpy().

Referenced by sdp_message_parse_a(), sdp_message_parse_b(), sdp_message_parse_c(), sdp_message_parse_k(), sdp_message_parse_m(), sdp_message_parse_o(), and sdp_message_parse_t().

Here is the call graph for this function:

Here is the caller graph for this function:

int osip_atoi ( const char *  number  ) 

Definition at line 214 of file osip_port.c.

unsigned int osip_build_random_number ( void   ) 

Definition at line 116 of file osip_port.c.

References random_seed_set.

char* osip_clrncpy ( char *  dst,
const char *  src,
size_t  len 
)

Definition at line 1144 of file osip_port.c.

int osip_clrspace ( char *  word  ) 

Definition at line 388 of file osip_port.c.

void osip_dequote ( char *  s  ) 

Definition at line 596 of file osip_port.c.

char* osip_enquote ( const char *  s  ) 

Definition at line 564 of file osip_port.c.

References osip_malloc.

unsigned long osip_hash ( const char *  str  ) 

Definition at line 1090 of file osip_port.c.

int osip_is_trace_level_activate ( osip_trace_level_t  level  ) 

Definition at line 645 of file osip_port.c.

References LOG_FALSE.

void osip_set_allocators ( osip_malloc_func_t malloc_func,
osip_realloc_func_t realloc_func,
osip_free_func_t free_func 
)

Definition at line 917 of file osip_port.c.

References osip_free_func, osip_malloc_func, and osip_realloc_func.

char* osip_str_append ( char *  dst,
const char *  src 
)

Definition at line 1115 of file osip_port.c.

int osip_strcasecmp ( const char *  s1,
const char *  s2 
)

Definition at line 344 of file osip_port.c.

char* osip_strdup ( const char *  ch  ) 

Definition at line 296 of file osip_port.c.

References osip_malloc, and osip_strncpy().

Referenced by sdp_message_parse_o(), and sdp_message_parse_s().

Here is the call graph for this function:

Here is the caller graph for this function:

char* osip_strdup_without_quote ( const char *  ch  ) 

Definition at line 310 of file osip_port.c.

References osip_malloc, and osip_strncpy().

Here is the call graph for this function:

char* osip_strn_append ( char *  dst,
const char *  src,
size_t  len 
)

Definition at line 1130 of file osip_port.c.

int osip_strncasecmp ( const char *  s1,
const char *  s2,
size_t  len 
)

Definition at line 363 of file osip_port.c.

char* osip_strncpy ( char *  dest,
const char *  src,
size_t  length 
)

Definition at line 231 of file osip_port.c.

Referenced by __osip_sdp_append_string(), __osip_set_next_token(), osip_strdup(), osip_strdup_without_quote(), sdp_message_parse_e(), sdp_message_parse_i(), sdp_message_parse_p(), sdp_message_parse_r(), sdp_message_parse_s(), sdp_message_parse_u(), sdp_message_parse_v(), and sdp_message_parse_z().

Here is the caller graph for this function:

int osip_tolower ( char *  word  ) 

Definition at line 325 of file osip_port.c.

int osip_trace ( char *  fi,
int  li,
osip_trace_level_t  level,
FILE *  f,
char *  chfr,
  ... 
)

Definition at line 755 of file osip_port.c.

References LOG_FALSE, logfile, OSIP_BUG, OSIP_ERROR, OSIP_FATAL, OSIP_INFO1, OSIP_INFO2, OSIP_INFO3, OSIP_INFO4, OSIP_WARNING, trace_func, tracing_table, use_syslog, and VA_START.

Referenced by sdp_message_parse().

Here is the caller graph for this function:

void osip_trace_disable_level ( osip_trace_level_t  level  ) 

Definition at line 640 of file osip_port.c.

void osip_trace_enable_level ( osip_trace_level_t  level  ) 

Definition at line 636 of file osip_port.c.

void osip_trace_initialize ( osip_trace_level_t  level,
FILE *  file 
)

Definition at line 632 of file osip_port.c.

void osip_trace_initialize_func ( osip_trace_level_t  level,
osip_trace_func_t func 
)

Definition at line 624 of file osip_port.c.

void osip_trace_initialize_syslog ( osip_trace_level_t  level,
char *  ident 
)

Definition at line 628 of file osip_port.c.

void osip_usleep ( int  useconds  ) 

Definition at line 260 of file osip_port.c.

References sec().

Here is the call graph for this function:


Variable Documentation

FILE* logfile = NULL

Definition at line 101 of file osip_port.c.

Referenced by osip_trace().

osip_free_func_t* osip_free_func = 0

Definition at line 111 of file osip_port.c.

Referenced by osip_set_allocators().

osip_malloc_func_t* osip_malloc_func = 0

Definition at line 109 of file osip_port.c.

Referenced by osip_set_allocators().

osip_realloc_func_t* osip_realloc_func = 0

Definition at line 110 of file osip_port.c.

Referenced by osip_set_allocators().

unsigned int random_seed_set = 0 [static]

Definition at line 106 of file osip_port.c.

Referenced by osip_build_random_number().

osip_trace_func_t* trace_func = 0 [static]

Definition at line 104 of file osip_port.c.

Referenced by osip_trace().

int tracing_table[END_TRACE_LEVEL]

Definition at line 102 of file osip_port.c.

Referenced by osip_trace().

int use_syslog = 0 [static]

Definition at line 103 of file osip_port.c.

Referenced by osip_trace().


Generated on Fri Mar 9 20:08:58 2007 for MAD-FCL by  doxygen 1.5.0