This is the second part of this chapter. Now we will introduce two new important concepts. The first one is the
failure_route and the second one is the
append_branch used to fork the call. We will handle the following failure situations:
To implement call forward on busy and call forward when unanswered, we will use the concept of the failure route.
In the logic below, just before sending the INVITE to the standard processing we will call the function
t_on_failure("1"). This allows us to handle the SIP failure messages (with reply codes higher than 299, ...