This header is used to switch between using the CDiameterPeer from SER or as a standalone server.
Definition in file utils.h.
#include "../../dprint.h"
#include "../../str.h"
#include "../../mem/mem.h"
#include "../../mem/shm_mem.h"
#include "../../locking.h"
#include "../../pt.h"
Go to the source code of this file.
Defines | |
| #define | LOG_NO_MEM(mem_type, data_len) |
| #define | shm_str_dup(dst, src) |
| #define LOG_NO_MEM | ( | mem_type, | |||
| data_len | ) |
Value:
LOG(L_ERR,"ERROR:%s:%s()[%d]: Out of %s memory allocating %d bytes\n",\
__FILE__,__FUNCTION__,__LINE__, \
mem_type,data_len);
Definition at line 82 of file utils.h.
Referenced by acceptor_process(), add_timer(), add_trans(), cb_add(), diameter_peer_init(), dp_add_pid(), new_dp_config(), new_peer(), new_routing_entry(), new_routing_realm(), parse_dp_config(), quote_trim_dup(), receive_loop(), session_init(), trans_init(), and worker_init().
| #define shm_str_dup | ( | dst, | |||
| src | ) |
Value:
{\
(dst).s = shm_malloc((src).len+1);\
if (!(dst).s){LOG_NO_MEM("shm",(src).len+1);}\
else {memcpy((dst).s,(src).s,(src).len);(dst).s[(src).len]=0;(dst).len=(src).len;}\
}
Definition at line 87 of file utils.h.
Referenced by new_peer().
1.5.2