From 2ae95b37546b9c7b01c72f926266be5b2eb0da51 Mon Sep 17 00:00:00 2001 From: Michael Jerris Date: Fri, 11 May 2007 17:04:24 +0000 Subject: [PATCH] backport change from the iaxclient sf repository rev 567 git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5153 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- libs/iax/src/iax.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libs/iax/src/iax.c b/libs/iax/src/iax.c index 54a18515a8..6bafc65d13 100644 --- a/libs/iax/src/iax.c +++ b/libs/iax/src/iax.c @@ -2993,6 +2993,7 @@ struct iax_event *iax_net_process(unsigned char *buf, int len, struct sockaddr_i if (len < sizeof(struct ast_iax2_full_hdr)) { DEBU(G "Short header received from %s\n", inet_ntoa(sin->sin_addr)); IAXERROR "Short header received from %s\n", inet_ntoa(sin->sin_addr)); + return NULL; } /* Only allow it to make new sessions on types where that makes sense */ if ((fh->type == AST_FRAME_IAX) && ((subclass == IAX_COMMAND_NEW) || @@ -3015,6 +3016,7 @@ struct iax_event *iax_net_process(unsigned char *buf, int len, struct sockaddr_i if (len < sizeof(struct ast_iax2_mini_hdr)) { DEBU(G "Short header received from %s\n", inet_ntoa(sin->sin_addr)); IAXERROR "Short header received from %s\n", inet_ntoa(sin->sin_addr)); + return NULL; } /* Miniature, voice frame */ session = iax_find_session(sin, ntohs(fh->scallno), 0, 0);