MCPcopy Create free account
hub / github.com/OpenSIPS/opensips / msg_callback_process

Function msg_callback_process

msg_callbacks.c:62–82  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

60}
61
62void
63msg_callback_process(struct sip_msg *msg, cb_type_t cb_type, void *core_arg)
64{
65 struct msg_callback *msg_cb;
66 struct msg_callback *msg_cb_pre;
67
68 for (msg_cb = msg->msg_cb; msg_cb != NULL; msg_cb = msg_cb->next) {
69 if (msg_cb->cb_type != cb_type) {
70 continue;
71 }
72 /* Execute callback */
73 msg_cb->cb_func(msg, cb_type, msg_cb->cb_arg, core_arg);
74 }
75 if (cb_type != MSG_DESTROY)
76 return;
77 for (msg_cb_pre = msg->msg_cb; msg_cb_pre != NULL; msg_cb_pre = msg_cb) {
78 msg_cb = msg_cb_pre->next;
79 pkg_free(msg_cb_pre);
80 }
81 msg->msg_cb = NULL;
82}
83
84int
85msg_callback_check(struct sip_msg *msg, cb_type_t cb_type, cb_func_t cb_func)

Callers 4

forward_requestFunction · 0.85
free_faked_reqFunction · 0.85
add_uacFunction · 0.85
free_sip_msgFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected