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

Function t_on_reply

modules/tm/t_reply.c:161–179  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

159
160
161void t_on_reply( struct script_route_ref *ref )
162{
163 struct cell *t = get_t();
164
165 struct script_route_ref **holder;
166
167 /* in MODE_REPLY and MODE_ONFAILURE T will be set to current transaction;
168 * in MODE_REQUEST T will be set only if the transaction was already
169 * created; if not -> use the static variable */
170 holder = (!t || t==T_UNDEFINED ) ? &goto_on_reply :
171 ( route_type==BRANCH_ROUTE ?
172 &TM_BRANCH(t,_tm_branch_index).on_reply : &t->on_reply );
173
174 /* if something already set, free it first */
175 if (*holder)
176 shm_free( *holder );
177
178 *holder = ref ? dup_ref_script_route_in_shm( ref, 0) : NULL;
179}
180
181
182struct script_route_ref *get_on_negative(void)

Callers 2

script_initFunction · 0.85
w_t_on_replyFunction · 0.85

Calls 3

get_tFunction · 0.85
shm_freeFunction · 0.85

Tested by

no test coverage detected