comparison libfreeDiameter/messages.c @ 37:cc3c59fe98fe

Lot of cleanups in peer structure management
author Sebastien Decugis <sdecugis@nict.go.jp>
date Thu, 05 Nov 2009 14:28:46 +0900
parents 6486e97f56ae
children c662d3eb6ff6
comparison
equal deleted inserted replaced
36:1498b3c7304c 37:cc3c59fe98fe
1060 TRACE_ENTRY("%p", msg); 1060 TRACE_ENTRY("%p", msg);
1061 1061
1062 CHECK_PARAMS_DO( CHECK_MSG(msg), return 0 /* pretend the message is not routable */ ); 1062 CHECK_PARAMS_DO( CHECK_MSG(msg), return 0 /* pretend the message is not routable */ );
1063 1063
1064 if ( ! msg->msg_routable ) { 1064 if ( ! msg->msg_routable ) {
1065 /* To define if a message is routable, we rely on the "PXY" command flag yet. */ 1065 /* To define if a message is routable, we rely on the "PXY" flag (for application 0). */
1066 msg->msg_routable = (msg->msg_public.msg_flags & CMD_FLAG_PROXIABLE) ? 1 : 2; 1066 msg->msg_routable = ((msg->msg_public.msg_appl != 0) || (msg->msg_public.msg_flags & CMD_FLAG_PROXIABLE)) ? 1 : 2;
1067 1067
1068 /* Note : the 'real' criteria according to the Diameter I-D is that the message is 1068 /* Note : the 'real' criteria according to the Diameter I-D is that the message is
1069 routable if and only if the "Destination-Realm" AVP is required by the command ABNF. 1069 routable if and only if the "Destination-Realm" AVP is required by the command ABNF.
1070 We could make a test for this here, but it's more computational work and our test 1070 We could make a test for this here, but it's more computational work and our test
1071 seems accurate (until proven otherwise...) */ 1071 seems accurate (until proven otherwise...) */
"Welcome to our mercurial repository"