Iñaki Baz Castillo writes:
So I wonder, shouldn't be better if we forgot the
t_relay() codes and
instead handle the error of the winning branch (even if it failed or
it was no branch) in failure_route?
inaki,
this has been discussed before and then the response has been that it is
impossible to enter failure route if transaction has not been created.
so there has not been any other choice that to live with this terrible
mess. now calling drop() in branch route seems to add one more
complication and produce errors to syslog.
Then any code we actually run into "if !
t_relay() { ... }" could be
executed in failure_route and we get an easier and solid way to handle
errors (instead of mixing t_relay negative values, local generated
negative responses in failure_route and so).
this has been proposed before, and the answer has been "can't be done".
-- juha