https://origsvn.digium.com/svn/asterisk/branches/10
........
r340031 | wedhorn | 2011-10-10 09:18:27 +1100 (Mon, 10 Oct 2011) | 8 lines
Return -1 to skinny_session if register rejected.
If device registration is rejected, return -1 so that the session is
destroyed immediately. Previously, a segfault would occur on a
graceful shutdown if a register is rejected and the skinny_session
has not yet timed out.
........
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@340032
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
transmit_capabilitiesreq(s->device);
} else {
transmit_registerrej(s);
+ ast_free(req);
+ return -1;
}
case IP_PORT_MESSAGE:
res = handle_ip_port_message(req, s);
res = handle_message(req, s);
if (res < 0) {
destroy_session(s);
+ ast_verb(3, "Ending Skinny session from %s\n", ast_inet_ntoa(s->sin.sin_addr));
return NULL;
}
}