Module: sip-router Branch: master Commit: 78669def2790205270032f9a750b19cc86f3d560 URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=78669def...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: Sun May 19 10:22:10 2013 +0200
tm: added icode to uac_client structure
- store internal processing code, to give hints of what happened - could be used to map sip warning codes http://www.iana.org/assignments/sip-parameters/sip-parameters.xml#sip-parame... - delivery failure on case of no connection mapped temporarly to 908
---
modules/tm/h_table.h | 3 +++ modules/tm/t_fwd.c | 1 + 2 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/modules/tm/h_table.h b/modules/tm/h_table.h index a3d22da..744f979 100644 --- a/modules/tm/h_table.h +++ b/modules/tm/h_table.h @@ -241,6 +241,9 @@ typedef struct ua_client #endif /* per branch flags */ flag_t branch_flags; + /* internal processing code - (mapping over sip warning codes) + * - storing the code giving a clue of what happened internally */ + int icode; #ifdef WITH_AS_SUPPORT /** * Resent for every rcvd 2xx reply. diff --git a/modules/tm/t_fwd.c b/modules/tm/t_fwd.c index 8d4308e..78d88f2 100644 --- a/modules/tm/t_fwd.c +++ b/modules/tm/t_fwd.c @@ -1585,6 +1585,7 @@ int t_send_branch( struct cell *t, int branch, struct sip_msg* p_msg , } } #endif + uac->icode = 908; /* internal code set to delivery failure */ LOG(L_ERR, "ERROR: t_send_branch: sending request on branch %d " "failed\n", branch); if (proxy) { proxy->errors++; proxy->ok=0; }