comparison libfdproto/messages.c @ 919:b1776283d69e

Do not kill framework when a message with 0b session-id is dispatched
author Sebastien Decugis <sdecugis@freediameter.net>
date Tue, 12 Feb 2013 18:19:19 +0100
parents 058e95c3a336
children cb439d57d0c5
comparison
equal deleted inserted replaced
918:46f9982b7d26 919:b1776283d69e
1258 } 1258 }
1259 1259
1260 ASSERT( avp->avp_public.avp_value ); 1260 ASSERT( avp->avp_public.avp_value );
1261 1261
1262 /* Resolve the session and we are done */ 1262 /* Resolve the session and we are done */
1263 CHECK_FCT( fd_sess_fromsid_msg ( avp->avp_public.avp_value->os.data, avp->avp_public.avp_value->os.len, &msg->msg_sess, new) ); 1263 if (avp->avp_public.avp_value->os.len > 0) {
1264 *session = msg->msg_sess; 1264 CHECK_FCT( fd_sess_fromsid_msg ( avp->avp_public.avp_value->os.data, avp->avp_public.avp_value->os.len, &msg->msg_sess, new) );
1265 *session = msg->msg_sess;
1266 } else {
1267 TRACE_DEBUG(FULL, "Session-Id AVP with 0-byte length found in message %p", msg);
1268 *session = NULL;
1269 }
1265 1270
1266 return 0; 1271 return 0;
1267 } 1272 }
1268 1273
1269 1274
"Welcome to our mercurial repository"