Kannel: Open Source WAP and SMS gateway
svn-r5336
|
Go to the source code of this file.
Macros | |
#define | MEMALIGN(x) ((x)+(8-(((unsigned long)(x))&0x7))) |
Enumerations | |
enum | { RAND, GETHOSTBYNAME, GWTIME, NUM_LOCKS } |
Functions | |
static void | lock (int which) |
static void | unlock (int which) |
void | gwlib_protected_init (void) |
void | gwlib_protected_shutdown (void) |
struct tm | gw_localtime (time_t t) |
struct tm | gw_gmtime (time_t t) |
time_t | gw_mktime (struct tm *tm) |
size_t | gw_strftime (char *s, size_t max, const char *format, const struct tm *tm) |
int | gw_rand (void) |
int | gw_gethostbyname (struct hostent *ent, const char *name, char **buff) |
Variables | |
static Mutex | locks [NUM_LOCKS] |
#define MEMALIGN | ( | x | ) | ((x)+(8-(((unsigned long)(x))&0x7))) |
Referenced by gw_gethostbyname().
anonymous enum |
Enumerator | |
---|---|
RAND | |
GETHOSTBYNAME | |
GWTIME | |
NUM_LOCKS |
Definition at line 80 of file protected.c.
int gw_gethostbyname | ( | struct hostent * | ent, |
const char * | name, | ||
char ** | buff | ||
) |
Definition at line 248 of file protected.c.
References GETHOSTBYNAME, gethostbyname, lock(), MEMALIGN, name, and unlock().
Referenced by make_server_socket(), setup_official_name(), tcpip_connect_nb_to_server_with_port(), tcpip_connect_to_server_with_port(), udp_bind(), and udp_create_address().
struct tm gw_gmtime | ( | time_t | t | ) |
Definition at line 137 of file protected.c.
References gmtime, GWTIME, lock(), and unlock().
Referenced by date_create_iso(), date_format_http(), delivery_time_constraints(), format(), get_pattern(), make_timestamp(), msg_to_pdu(), obey_request(), set_time(), status_cb(), timestamp_to_minutes(), and urltrans_fill_escape_codes().
struct tm gw_localtime | ( | time_t | t | ) |
Definition at line 121 of file protected.c.
References GWTIME, localtime, lock(), and unlock().
Referenced by format(), msg_to_emimsg(), msg_to_pdu(), status_cb(), and timestamp_to_minutes().
time_t gw_mktime | ( | struct tm * | tm | ) |
Definition at line 153 of file protected.c.
References GWTIME, lock(), mktime, and unlock().
Referenced by clickatell_receive_sms(), parse_http_date(), and timestamp_to_minutes().
int gw_rand | ( | void | ) |
Definition at line 174 of file protected.c.
References lock(), RAND, rand, and unlock().
Referenced by choose_message(), gw_generate_id(), randomize(), route_incoming_to_boxc(), route_msg(), set_zero(), smsc2_rout(), soap_rand_attribute(), url_pattern(), and wap_msg_recv().
size_t gw_strftime | ( | char * | s, |
size_t | max, | ||
const char * | format, | ||
const struct tm * | tm | ||
) |
Definition at line 164 of file protected.c.
References GWTIME, lock(), strftime, and unlock().
Referenced by msg_to_pdu().
void gwlib_protected_init | ( | void | ) |
Definition at line 103 of file protected.c.
References locks, mutex_init_static, and NUM_LOCKS.
Referenced by gwlib_init().
void gwlib_protected_shutdown | ( | void | ) |
Definition at line 112 of file protected.c.
References locks, mutex_destroy(), and NUM_LOCKS.
Referenced by gwlib_shutdown().
|
static |
Definition at line 91 of file protected.c.
References locks, and mutex_lock.
Referenced by gw_gethostbyname(), gw_gmtime(), gw_localtime(), gw_mktime(), gw_rand(), and gw_strftime().
|
static |
Definition at line 97 of file protected.c.
References locks, and mutex_unlock.
Referenced by gw_gethostbyname(), gw_gmtime(), gw_localtime(), gw_mktime(), gw_rand(), and gw_strftime().
Definition at line 88 of file protected.c.
Referenced by gwlib_protected_init(), gwlib_protected_shutdown(), lock(), and unlock().